From 8efc500a7465c03877db8bbe443134f2b1bbc1af Mon Sep 17 00:00:00 2001 From: Matteo Martincigh Date: Thu, 10 Oct 2019 14:30:29 +0100 Subject: IVGCVSW-3963 Implement the Request Counter Directory Handler * Integrated the RequestCounterDirectoryCommandHandler in the ProfilingService class * Code refactoring * Added/Updated unit tests Signed-off-by: Matteo Martincigh Change-Id: I60d9f8acf166e29b3dabc921dbdb8149461bd85f --- src/profiling/test/ProfilingTests.hpp | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) (limited to 'src/profiling/test/ProfilingTests.hpp') diff --git a/src/profiling/test/ProfilingTests.hpp b/src/profiling/test/ProfilingTests.hpp index 3e6cf63efe..e1686162db 100644 --- a/src/profiling/test/ProfilingTests.hpp +++ b/src/profiling/test/ProfilingTests.hpp @@ -40,17 +40,6 @@ public: } }; -struct CoutRedirect -{ -public: - CoutRedirect(std::streambuf* newStreamBuffer) - : m_Old(std::cout.rdbuf(newStreamBuffer)) {} - ~CoutRedirect() { std::cout.rdbuf(m_Old); } - -private: - std::streambuf* m_Old; -}; - struct StreamRedirector { public: @@ -190,6 +179,11 @@ public: return boost::polymorphic_downcast(profilingConnection); } + void ForceTransitionToState(ProfilingState newState) + { + TransitionToState(ProfilingService::Instance(), newState); + } + private: MockProfilingConnectionFactoryPtr m_MockProfilingConnectionFactory; IProfilingConnectionFactory* m_BackupProfilingConnectionFactory; -- cgit v1.2.1