From 7a2d4cc8bfbbc3b4386cee6333a966acd09e9c74 Mon Sep 17 00:00:00 2001 From: Scott Moser Date: Tue, 19 Sep 2017 14:28:39 -0400 Subject: tests: fix ds-identify unit tests to set EC2_STRICT_ID_DEFAULT. The variable DI_EC2_STRICT_ID_DEFAULT was not being set in unit tests so when 16.04 built, which changed that setting in patches the tests would unexpectedly fail. --- tests/unittests/test_ds_identify.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/unittests/test_ds_identify.py b/tests/unittests/test_ds_identify.py index 92454d7c..1284e755 100644 --- a/tests/unittests/test_ds_identify.py +++ b/tests/unittests/test_ds_identify.py @@ -31,6 +31,7 @@ POLICY_FOUND_ONLY = "search,found=all,maybe=none,notfound=disabled" POLICY_FOUND_OR_MAYBE = "search,found=all,maybe=all,notfound=disabled" DI_DEFAULT_POLICY = "search,found=all,maybe=all,notfound=enabled" DI_DEFAULT_POLICY_NO_DMI = "search,found=all,maybe=all,notfound=disabled" +DI_EC2_STRICT_ID_DEFAULT = "true" SHELL_MOCK_TMPL = """\ %(name)s() { @@ -62,7 +63,8 @@ class TestDsIdentify(CiTestCase): def call(self, rootd=None, mocks=None, args=None, files=None, policy_dmi=DI_DEFAULT_POLICY, - policy_no_dmi=DI_DEFAULT_POLICY_NO_DMI): + policy_no_dmi=DI_DEFAULT_POLICY_NO_DMI, + ec2_strict_id=DI_EC2_STRICT_ID_DEFAULT): if args is None: args = [] if mocks is None: @@ -89,6 +91,7 @@ class TestDsIdentify(CiTestCase): ". " + self.dsid_path, 'DI_DEFAULT_POLICY="%s"' % policy_dmi, 'DI_DEFAULT_POLICY_NO_DMI="%s"' % policy_no_dmi, + 'DI_EC2_STRICT_ID_DEFAULT="%s"' % ec2_strict_id, "" ] -- cgit v1.2.3