mirror of
https://github.com/ansible/awx.git
synced 2026-05-09 02:17:37 -02:30
Update unit tests
This commit is contained in:
@@ -1929,9 +1929,7 @@ def test_notification_job_finished(mocker):
|
|||||||
uj.send_notification_templates.assert_called()
|
uj.send_notification_templates.assert_called()
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.django_db
|
def test_job_run_no_ee(execution_environment, private_data_dir, job):
|
||||||
class TestNullExecutionEnvironment(TestJobExecution):
|
|
||||||
def test_job_run_no_ee(self, execution_environment, private_data_dir, job):
|
|
||||||
org = Organization(pk=1)
|
org = Organization(pk=1)
|
||||||
proj = Project(pk=1, organization=org)
|
proj = Project(pk=1, organization=org)
|
||||||
job = Job(project=proj, organization=org, inventory=Inventory(pk=1))
|
job = Job(project=proj, organization=org, inventory=Inventory(pk=1))
|
||||||
@@ -1949,7 +1947,8 @@ class TestNullExecutionEnvironment(TestJobExecution):
|
|||||||
assert update_model_call['status'] == 'error'
|
assert update_model_call['status'] == 'error'
|
||||||
assert 'Job could not start because no Execution Environment could be found' in str(e.value)
|
assert 'Job could not start because no Execution Environment could be found' in str(e.value)
|
||||||
|
|
||||||
def test_project_update_no_ee(self, execution_environment, job):
|
|
||||||
|
def test_project_update_no_ee(execution_environment, job):
|
||||||
org = Organization(pk=1)
|
org = Organization(pk=1)
|
||||||
proj = Project(pk=1, organization=org)
|
proj = Project(pk=1, organization=org)
|
||||||
project_update = ProjectUpdate(pk=1, project=proj, scm_type='git')
|
project_update = ProjectUpdate(pk=1, project=proj, scm_type='git')
|
||||||
|
|||||||
Reference in New Issue
Block a user