Merge "Add metadata to test_case_creator"
diff --git a/script/configure/test_case_creator.py b/script/configure/test_case_creator.py
index 3e68771..76a143b 100755
--- a/script/configure/test_case_creator.py
+++ b/script/configure/test_case_creator.py
@@ -47,6 +47,7 @@
         test_type: string, type of the test, currently support host and target.
         test_name_prefix: prefix of generated test name. e.g. android.hardware.nfc@1.0-test-target.
         test_name: test name generated. e.g. android.hardware.nfc@1.0-test-target-profiling.
+        test_plan: string, the plan that the test belongs to.
         test_dir: string, test case absolute directory.
         time_out: string, timeout of the test, default is 1m.
         is_profiling: boolean, whether to create a profiling test case.
@@ -101,10 +102,13 @@
 
         self._test_module_name = self.GetVtsHalTestModuleName()
         self._test_name = self._test_module_name
+        self._test_plan = 'vts-staging-default'
         if is_replay:
             self._test_name = self._test_module_name + 'Replay'
+            self._test_plan = 'vts-hal-replay'
         if is_profiling:
             self._test_name = self._test_module_name + 'Profiling'
+            self._test_plan = 'vts-hal-profiling'
 
         self._test_dir = self.GetHalTestCasePath()
         # Check whether the host side test script and target test binary is available.
@@ -216,6 +220,13 @@
         configuration = ET.Element('configuration', {
             'description': 'Config for VTS ' + self._test_name + ' test cases'
         })
+
+        ET.SubElement(configuration, 'option', {
+            'name': 'config-descriptor:metadata',
+            'key': 'plan',
+            'value': self._test_plan
+        })
+
         file_pusher = ET.SubElement(configuration, 'target_preparer',
                                     {'class': VTS_FILE_PUSHER})