Signed-off-by: Jiří Župka <jzupka@xxxxxxxxxx> --- virttest/cartesian_config_unittest.py | 79 +++++++++++++++++++++++++++++++++++ 1 file changed, 79 insertions(+) diff --git a/virttest/cartesian_config_unittest.py b/virttest/cartesian_config_unittest.py index afc1b14..98c1efc 100755 --- a/virttest/cartesian_config_unittest.py +++ b/virttest/cartesian_config_unittest.py @@ -86,6 +86,85 @@ class CartesianConfigTest(unittest.TestCase): ) + def testNameVariant(self): + self._checkStringDump(""" + variants name=tests: # All tests in configuration + - wait: + run = "wait" + variants: + - long: + time = short_time + - short: long + time = logn_time + - test2: + run = "test1" + + variants name=virt_system: + - @linux: + - windows: + + variants name=host_os: + - linux: + image = linux + - windows: + image = windows + + only host_os>linux + """, + [ + {'dep': [], + 'host_os': 'linux', + 'image': 'linux', + 'name': 'host_os>linux.virt_system>linux.tests>wait.long', + 'run': 'wait', + 'shortname': 'host_os>linux.tests>wait.long', + 'tests': 'wait', + 'time': 'short_time', + 'virt_system': 'linux'}, + {'dep': ['host_os>linux.virt_system>linux.tests>wait.long'], + 'host_os': 'linux', + 'image': 'linux', + 'name': 'host_os>linux.virt_system>linux.tests>wait.short', + 'run': 'wait', + 'shortname': 'host_os>linux.tests>wait.short', + 'tests': 'wait', + 'time': 'logn_time', + 'virt_system': 'linux'}, + {'dep': [], + 'host_os': 'linux', + 'image': 'linux', + 'name': 'host_os>linux.virt_system>linux.tests>test2', + 'run': 'test1', + 'shortname': 'host_os>linux.tests>test2', + 'tests': 'test2', + 'virt_system': 'linux'}, + {'dep': [], + 'host_os': 'linux', + 'image': 'linux', + 'name': 'host_os>linux.virt_system>windows.tests>wait.long', + 'run': 'wait', + 'shortname': 'host_os>linux.virt_system>windows.tests>wait.long', + 'tests': 'wait', + 'time': 'short_time', + 'virt_system': 'windows'}, + {'dep': ['host_os>linux.virt_system>windows.tests>wait.long'], + 'host_os': 'linux', + 'image': 'linux', + 'name': 'host_os>linux.virt_system>windows.tests>wait.short', + 'run': 'wait', + 'shortname': 'host_os>linux.virt_system>windows.tests>wait.short', + 'tests': 'wait', + 'time': 'logn_time', + 'virt_system': 'windows'}, + {'dep': [], + 'host_os': 'linux', + 'image': 'linux', + 'name': 'host_os>linux.virt_system>windows.tests>test2', + 'run': 'test1', + 'shortname': 'host_os>linux.virt_system>windows.tests>test2', + 'tests': 'test2', + 'virt_system': 'windows'}, + ]) def testHugeTest1(self): self._checkConfigDump('testcfg.huge/test1.cfg', 'testcfg.huge/test1.cfg.repr.gz') -- 1.8.1.4 -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html