fixing ad_hoc imports

flake8 fixes

Fix and add awx/api/tests

added fact tests

added proper xml reports for jenkins

added jenkins requirements and adjusted Makefile target
This commit is contained in:
Wayne Witzel III
2016-01-28 12:01:12 -05:00
parent 6eae492d28
commit 71a1547c3a
13 changed files with 26 additions and 19 deletions

View File

@@ -5,7 +5,7 @@ from django.conf import settings
from django.test import LiveServerTestCase
from django.test.utils import override_settings
from awx.main.tests.jobs import BaseJobTestMixin
from awx.main.tests.job_base import BaseJobTestMixin
@override_settings(CELERY_ALWAYS_EAGER=True,

View File

@@ -470,3 +470,4 @@ class Credential(PasswordFieldsModel, CommonModelNameNotUnique):
if 'cloud' not in update_fields:
update_fields.append('cloud')
super(Credential, self).save(*args, **kwargs)

View File

@@ -19,7 +19,11 @@ from crum import impersonate
from awx.main.utils import * # noqa
from awx.main.models import * # noqa
from awx.main.tests.base import BaseJobExecutionTest
from tasks import TEST_SSH_KEY_DATA, TEST_SSH_KEY_DATA_LOCKED, TEST_SSH_KEY_DATA_UNLOCK
from awx.main.tests.data.ssh import (
TEST_SSH_KEY_DATA,
TEST_SSH_KEY_DATA_LOCKED,
TEST_SSH_KEY_DATA_UNLOCK,
)
__all__ = ['RunAdHocCommandTest', 'AdHocCommandApiTest']

View File

@@ -10,7 +10,7 @@ from django.core.urlresolvers import reverse
# AWX
from awx.main.models import * # noqa
from job_base import BaseJobTestMixin
from awx.main.tests.job_base import BaseJobTestMixin
import yaml
__all__ = ['JobTemplateLaunchTest', 'JobTemplateLaunchPasswordsTest']

View File

@@ -11,7 +11,7 @@ from django.core.urlresolvers import reverse
# AWX
from awx.main.models import * # noqa
from awx.main.tests.base import BaseLiveServerTest
from job_base import BaseJobTestMixin
from awx.main.tests.job_base import BaseJobTestMixin
__all__ = ['JobRelaunchTest',]

View File

@@ -22,7 +22,7 @@ import requests
# AWX
from awx.main.models import * # noqa
from job_base import BaseJobTestMixin
from awx.main.tests.job_base import BaseJobTestMixin
__all__ = ['JobTemplateTest', 'JobTest', 'JobTemplateCallbackTest', 'JobTransactionTest', 'JobTemplateSurveyTest']

View File

@@ -11,7 +11,7 @@ from django.conf import settings
# AWX
from awx.main.models import * # noqa
from awx.main.tests.base import BaseLiveServerTest
from job_base import BaseJobTestMixin
from awx.main.tests.job_base import BaseJobTestMixin
__all__ = ['JobStartCancelTest',]

View File

@@ -257,8 +257,8 @@ class BaseJobTestMixin(BaseTestMixin):
# Each user has his/her own set of credentials.
from awx.main.tests.data.ssh import (TEST_SSH_KEY_DATA,
TEST_SSH_KEY_DATA_LOCKED,
TEST_SSH_KEY_DATA_UNLOCK)
TEST_SSH_KEY_DATA_LOCKED,
TEST_SSH_KEY_DATA_UNLOCK)
self.cred_sue = self.user_sue.credentials.create(
username='sue',
password=TEST_SSH_KEY_DATA,

View File

@@ -20,7 +20,6 @@ import tempfile
from rest_framework.exceptions import ParseError, PermissionDenied
from django.utils.encoding import smart_str
from django.core.urlresolvers import reverse
from django.core.exceptions import ValidationError
# PyCrypto
from Crypto.Cipher import AES