More deletions of 'any' state

This commit is contained in:
beeankha 2019-06-13 11:16:05 -04:00
parent c6f1806a23
commit f5b6bd65cf
8 changed files with 9 additions and 14 deletions

View File

@ -13,7 +13,6 @@ from awx.api.views import (
InventorySourceCredentialsList,
InventorySourceGroupsList,
InventorySourceHostsList,
InventorySourceNotificationTemplatesAnyList,
InventorySourceNotificationTemplatesErrorList,
InventorySourceNotificationTemplatesStartedList,
InventorySourceNotificationTemplatesSuccessList,

View File

@ -13,7 +13,6 @@ from awx.api.views import (
JobTemplateSchedulesList,
JobTemplateSurveySpec,
JobTemplateActivityStreamList,
JobTemplateNotificationTemplatesAnyList,
JobTemplateNotificationTemplatesErrorList,
JobTemplateNotificationTemplatesStartedList,
JobTemplateNotificationTemplatesSuccessList,

View File

@ -15,7 +15,6 @@ from awx.api.views import (
OrganizationCredentialList,
OrganizationActivityStreamList,
OrganizationNotificationTemplatesList,
OrganizationNotificationTemplatesAnyList,
OrganizationNotificationTemplatesErrorList,
OrganizationNotificationTemplatesStartedList,
OrganizationNotificationTemplatesSuccessList,

View File

@ -14,7 +14,6 @@ from awx.api.views import (
ProjectUpdatesList,
ProjectActivityStreamList,
ProjectSchedulesList,
ProjectNotificationTemplatesAnyList,
ProjectNotificationTemplatesErrorList,
ProjectNotificationTemplatesStartedList,
ProjectNotificationTemplatesSuccessList,

View File

@ -9,7 +9,6 @@ from awx.api.views import (
SystemJobTemplateLaunch,
SystemJobTemplateJobsList,
SystemJobTemplateSchedulesList,
SystemJobTemplateNotificationTemplatesAnyList,
SystemJobTemplateNotificationTemplatesErrorList,
SystemJobTemplateNotificationTemplatesStartedList,
SystemJobTemplateNotificationTemplatesSuccessList,

View File

@ -13,7 +13,6 @@ from awx.api.views import (
WorkflowJobTemplateSurveySpec,
WorkflowJobTemplateWorkflowNodesList,
WorkflowJobTemplateActivityStreamList,
WorkflowJobTemplateNotificationTemplatesAnyList,
WorkflowJobTemplateNotificationTemplatesErrorList,
WorkflowJobTemplateNotificationTemplatesStartedList,
WorkflowJobTemplateNotificationTemplatesSuccessList,

View File

@ -42,7 +42,7 @@ def test_inventory_source_notification_on_cloud_only(get, post, inventory_source
not_is = inventory_source_factory("not_ec2")
# Delete the below portion?
# Delete the below portion? ******
# url = reverse('api:inventory_source_notification_templates_any_list', kwargs={'pk': cloud_is.id})
# response = post(url, dict(id=notification_template.id), u)
# assert response.status_code == 204

View File

@ -92,7 +92,7 @@ def test_inherited_notification_templates(get, post, user, organization, project
isrc.save()
jt = JobTemplate.objects.create(name='test', inventory=i, project=project, playbook='debug.yml')
jt.save()
# What can we replace the below tests with?
# What can we replace the below tests with? ******
# url = reverse('api:organization_notification_templates_any_list', kwargs={'pk': organization.id})
# response = post(url, dict(id=notification_templates[0]), u)
# assert response.status_code == 204
@ -107,12 +107,13 @@ def test_inherited_notification_templates(get, post, user, organization, project
# assert len(isrc.notification_templates['any']) == 1
@pytest.mark.django_db
def test_notification_template_merging(get, post, user, organization, project, notification_template):
user('admin-poster', True)
organization.notification_templates_any.add(notification_template)
project.notification_templates_any.add(notification_template)
assert len(project.notification_templates['any']) == 1
# Delete the test below? ******
# @pytest.mark.django_db
# def test_notification_template_merging(get, post, user, organization, project, notification_template):
# user('admin-poster', True)
# organization.notification_templates_any.add(notification_template)
# project.notification_templates_any.add(notification_template)
# assert len(project.notification_templates['any']) == 1
@pytest.mark.django_db