1
0
mirror of https://github.com/ansible/awx.git synced 2024-11-02 01:21:21 +03:00

use python2.6 safe unittest2

This commit is contained in:
Chris Meyers 2015-07-29 14:53:26 -04:00
parent d3984e45ba
commit 34ecd4e5b6
4 changed files with 4 additions and 7 deletions

View File

@ -11,7 +11,7 @@ import sys
import tempfile import tempfile
import time import time
import urlparse import urlparse
import unittest import unittest2 as unittest
# Django # Django
import django import django
@ -26,9 +26,6 @@ from django.test.utils import override_settings
from awx.main.models import * # noqa from awx.main.models import * # noqa
from awx.main.tests.base import BaseTest, BaseLiveServerTest from awx.main.tests.base import BaseTest, BaseLiveServerTest
if not hasattr(unittest, 'skipIf'):
import unittest2 as unittest
__all__ = ['CreateDefaultOrgTest', 'DumpDataTest', 'CleanupDeletedTest', __all__ = ['CreateDefaultOrgTest', 'DumpDataTest', 'CleanupDeletedTest',
'CleanupJobsTest', 'CleanupActivityStreamTest', 'CleanupJobsTest', 'CleanupActivityStreamTest',
'InventoryImportTest'] 'InventoryImportTest']

View File

@ -5,7 +5,7 @@
import time import time
from datetime import datetime from datetime import datetime
import mock import mock
import unittest import unittest2 as unittest
from copy import deepcopy from copy import deepcopy
from mock import MagicMock from mock import MagicMock

View File

@ -2,7 +2,7 @@
# All Rights Reserved # All Rights Reserved
# Python # Python
import unittest import unittest2 as unittest
# Django # Django
from django.core.urlresolvers import reverse from django.core.urlresolvers import reverse

View File

@ -8,7 +8,7 @@ import os
import shutil import shutil
import subprocess import subprocess
import tempfile import tempfile
import unittest import unittest2 as unittest
# Django # Django
from django.conf import settings from django.conf import settings