diff options
author | Vitaly Buka <vitalybuka@google.com> | 2016-02-22 17:18:49 -0800 |
---|---|---|
committer | Vitaly Buka <vitalybuka@google.com> | 2016-02-23 20:12:41 +0000 |
commit | 012cd9842559fd985d70a59919c382d71f15c5ac (patch) | |
tree | 2217469c4f695a524f71e8bc60a71d75f0656908 /src | |
parent | c6d99bb82ea9ceef4cf65a5b0c755bb1f119b639 (diff) | |
download | libweave-012cd9842559fd985d70a59919c382d71f15c5ac.tar.gz |
Move mock_component_manager.h into test/ dir
Change-Id: I4c3f95174a7fa83d9fc04fc75a89e4f908bb615a
Reviewed-on: https://weave-review.googlesource.com/2707
Reviewed-by: Alex Vakulenko <avakulenko@google.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/commands/cloud_command_proxy_unittest.cc | 4 | ||||
-rw-r--r-- | src/component_manager_unittest.cc | 4 | ||||
-rw-r--r-- | src/test/mock_component_manager.h (renamed from src/mock_component_manager.h) | 4 |
3 files changed, 8 insertions, 4 deletions
diff --git a/src/commands/cloud_command_proxy_unittest.cc b/src/commands/cloud_command_proxy_unittest.cc index 0de67fe..e0bd4fc 100644 --- a/src/commands/cloud_command_proxy_unittest.cc +++ b/src/commands/cloud_command_proxy_unittest.cc @@ -14,7 +14,7 @@ #include <weave/test/unittest_utils.h> #include "src/commands/command_instance.h" -#include "src/mock_component_manager.h" +#include "src/test/mock_component_manager.h" using testing::_; using testing::AnyNumber; @@ -141,7 +141,7 @@ class CloudCommandProxyTest : public ::testing::Test { ComponentManager::UpdateID current_state_update_id_{0}; base::CallbackList<void(ComponentManager::UpdateID)> callbacks_; testing::StrictMock<MockCloudCommandUpdateInterface> cloud_updater_; - testing::StrictMock<MockComponentManager> component_manager_; + testing::StrictMock<test::MockComponentManager> component_manager_; testing::StrictMock<provider::test::FakeTaskRunner> task_runner_; std::queue<base::Closure> task_queue_; std::unique_ptr<CommandInstance> command_instance_; diff --git a/src/component_manager_unittest.cc b/src/component_manager_unittest.cc index 97dc00d..c56567c 100644 --- a/src/component_manager_unittest.cc +++ b/src/component_manager_unittest.cc @@ -12,7 +12,7 @@ #include "src/bind_lambda.h" #include "src/commands/schema_constants.h" -#include "src/mock_component_manager.h" +#include "src/test/mock_component_manager.h" #include "src/test/mock_clock.h" namespace weave { @@ -1481,7 +1481,7 @@ TEST_F(ComponentManagerTest, GetLegacyState) { TEST_F(ComponentManagerTest, TestMockComponentManager) { // Check that all the virtual methods are mocked out. - MockComponentManager mock; + test::MockComponentManager mock; } } // namespace weave diff --git a/src/mock_component_manager.h b/src/test/mock_component_manager.h index addd6f0..1f470c2 100644 --- a/src/mock_component_manager.h +++ b/src/test/mock_component_manager.h @@ -11,6 +11,8 @@ namespace weave { +namespace test { + class MockComponentManager : public ComponentManager { public: ~MockComponentManager() override {} @@ -125,6 +127,8 @@ class MockComponentManager : public ComponentManager { } }; +} // namespace test + } // namespace weave #endif // LIBWEAVE_SRC_COMPONENT_MANAGER_H_ |