[coco] Share mock-up Use class (#1055)
author박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 <jh1302.park@samsung.com>
Thu, 16 Aug 2018 09:47:59 +0000 (18:47 +0900)
committerGitHub Enterprise <noreply-CODE@samsung.com>
Thu, 16 Aug 2018 09:47:59 +0000 (18:47 +0900)
This commit extracts mock-up Use class from UseHook/UseSlot tests, and
shares the extracted one for both tests.

Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
contrib/coco/core/src/IR/Use.mock.h [new file with mode: 0644]
contrib/coco/core/src/IR/UseHook.test.cpp
contrib/coco/core/src/IR/UseSlot.test.cpp

diff --git a/contrib/coco/core/src/IR/Use.mock.h b/contrib/coco/core/src/IR/Use.mock.h
new file mode 100644 (file)
index 0000000..830ffdd
--- /dev/null
@@ -0,0 +1,16 @@
+#ifndef __COCO_IR_USE_MOCK_H__
+#define __COCO_IR_USE_MOCK_H__
+
+#include "coco/IR/Object.h"
+
+namespace
+{
+namespace mock
+{
+struct Use final : public coco::Object::Use
+{
+};
+} // namespace mock
+} // namespace
+
+#endif // __COCO_IR_USE_MOCK_H__
index 5e9fb78..44169aa 100644 (file)
@@ -4,17 +4,9 @@
 
 #include "coco/IR/FeatureObject.h"
 
-#include <gtest/gtest.h>
+#include "Use.mock.h"
 
-namespace
-{
-namespace mock
-{
-struct Use final : public coco::Object::Use
-{
-};
-} // namespace mock
-} // namespace
+#include <gtest/gtest.h>
 
 namespace
 {
index bac3caf..1f7773b 100644 (file)
@@ -4,17 +4,9 @@
 
 #include "coco/IR/FeatureObject.h"
 
-#include <gtest/gtest.h>
+#include "Use.mock.h"
 
-namespace
-{
-namespace mock
-{
-struct Use final : public coco::Object::Use
-{
-};
-} // namespace mock
-} // namespace
+#include <gtest/gtest.h>
 
 namespace
 {