mirror of
https://github.com/ansible/awx.git
synced 2026-05-12 03:47:36 -02:30
fix bugs with system auditors and orphan JTs
This commit is contained in:
@@ -226,6 +226,14 @@ def test_job_template_access_org_admin(jt_objects, rando):
|
||||
assert access.can_delete(jt_objects.job_template)
|
||||
|
||||
|
||||
@pytest.mark.django_db
|
||||
def test_orphan_JT_readable_by_system_auditor(job_template, system_auditor):
|
||||
assert system_auditor.is_system_auditor
|
||||
assert job_template.project is None
|
||||
access = JobTemplateAccess(system_auditor)
|
||||
assert access.can_read(job_template)
|
||||
|
||||
|
||||
@pytest.mark.django_db
|
||||
@pytest.mark.job_permissions
|
||||
def test_job_template_creator_access(project, rando, post):
|
||||
|
||||
Reference in New Issue
Block a user