Browse Source

Skip amphora scenario test if provider is not set

This patch also removes py27 and py35 from list of envs in tox. We don't
have functional tests.

Change-Id: Id9255fe87d61bf6536c8d03f9dd7612abc451904
Carlos Goncalves 2 months ago
parent
commit
436dd9fe23
2 changed files with 10 additions and 1 deletions
  1. 9
    0
      octavia_tempest_plugin/tests/scenario/v2/test_amphora.py
  2. 1
    1
      tox.ini

+ 9
- 0
octavia_tempest_plugin/tests/scenario/v2/test_amphora.py View File

@@ -30,6 +30,15 @@ CONF = config.CONF
30 30
 class AmphoraScenarioTest(test_base.LoadBalancerBaseTest):
31 31
     """Test the amphora object API."""
32 32
 
33
+    @classmethod
34
+    def skip_checks(cls):
35
+        super(AmphoraScenarioTest, cls).skip_checks()
36
+
37
+        if CONF.load_balancer.provider not in ['amphora', 'octavia']:
38
+            raise cls.skipException("Amphora tests require provider 'amphora' "
39
+                                    "or 'octavia' (alias to 'amphora', "
40
+                                    " deprecated) set")
41
+
33 42
     @classmethod
34 43
     def resource_setup(cls):
35 44
         """Setup resources needed by the tests."""

+ 1
- 1
tox.ini View File

@@ -1,6 +1,6 @@
1 1
 [tox]
2 2
 minversion = 2.0
3
-envlist = py35,py27,pep8
3
+envlist = pep8
4 4
 skipsdist = True
5 5
 
6 6
 [testenv]

Loading…
Cancel
Save