]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commitdiff
Disable XML tests on Py26
authorMark McClain <mmcclain@yahoo-inc.com>
Thu, 20 Mar 2014 17:49:13 +0000 (13:49 -0400)
committerKevin Benton <blak111@gmail.com>
Thu, 27 Mar 2014 02:27:34 +0000 (02:27 +0000)
Unit testing on Py26 takes too long to run.  The code paths are the
same, so we'll temporarily skip tests is the class contains XML
formating since duplicate full stack JSON tests are run.

Change-Id: Ie8eddfe0b6af39f32380ce532e0c26acc0a6596d
Related-Bug: 1295281

neutron/tests/base.py

index ccdf0fc6bb0304ebbafa15b566d9e4d32a5b1581..a135010d15254f55f6dd552a35a3acf1f23e361e 100644 (file)
@@ -20,6 +20,7 @@
 import contextlib
 import logging
 import os
+import sys
 
 import eventlet.timeout
 import fixtures
@@ -117,6 +118,9 @@ class BaseTestCase(testtools.TestCase):
             'neutron.common.exceptions.NeutronException.use_fatal_exceptions',
             fake_use_fatal_exceptions))
 
+        if sys.version_info < (2, 7) and getattr(self, 'fmt', '') == 'xml':
+            raise self.skipException('XML Testing Skipped in Py26')
+
     def config(self, **kw):
         """Override some configuration values.