diff options
Diffstat (limited to 'tests/modules/common/qtmir_test.cpp')
-rw-r--r-- | tests/modules/common/qtmir_test.cpp | 61 |
1 files changed, 61 insertions, 0 deletions
diff --git a/tests/modules/common/qtmir_test.cpp b/tests/modules/common/qtmir_test.cpp new file mode 100644 index 0000000..33a6c27 --- /dev/null +++ b/tests/modules/common/qtmir_test.cpp @@ -0,0 +1,61 @@ +#include "qtmir_test.h" + +namespace qtmir { + +void PrintTo(const Application::InternalState& state, ::std::ostream* os) { + switch (state) { + case Application::InternalState::Starting: + *os << "Starting"; + break; + case Application::InternalState::Running: + *os << "Running"; + break; + case Application::InternalState::RunningInBackground: + *os << "RunningInBackground"; + break; + case Application::InternalState::SuspendingWaitSession: + *os << "SuspendingWaitSession"; + break; + case Application::InternalState::SuspendingWaitProcess: + *os << "SuspendingWaitProcess"; + break; + case Application::InternalState::Suspended: + *os << "Suspended"; + break; + case Application::InternalState::StoppedUnexpectedly: + *os << "StoppedUnexpectedly"; + break; + case Application::InternalState::Stopped: + *os << "Stopped"; + break; + default: + *os << "???"; + break; + } +} + +void PrintTo(const Session::State& state, ::std::ostream* os) +{ + switch (state) { + case SessionInterface::Starting: + *os << "Starting"; + break; + case SessionInterface::Running: + *os << "Running"; + break; + case SessionInterface::Suspending: + *os << "Suspending"; + break; + case SessionInterface::Suspended: + *os << "Suspended"; + break; + case SessionInterface::Stopped: + *os << "Stopped"; + break; + default: + *os << "???"; + break; + } +} + +} // namespace qtmir |