mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-05-19 10:59:21 +02:00
More stragglers
This commit is contained in:
parent
311296e24a
commit
9ab1be9ee1
2 changed files with 13 additions and 5 deletions
|
@ -149,8 +149,11 @@ class DomainApplicationTests(TestWithUser, WebTest):
|
|||
"""Test that an info message appears when user has multiple applications already"""
|
||||
# create and submit an application
|
||||
application = completed_application(user=self.user)
|
||||
application.submit()
|
||||
application.save()
|
||||
mock_client = MockSESClient()
|
||||
with boto3_mocking.clients.handler_for("sesv2", mock_client):
|
||||
with less_console_noise():
|
||||
application.submit()
|
||||
application.save()
|
||||
|
||||
# now, attempt to create another one
|
||||
with less_console_noise():
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import logging
|
||||
|
||||
import boto3_mocking # type: ignore
|
||||
from django.http import Http404, HttpResponse, HttpResponseRedirect
|
||||
from django.shortcuts import redirect, render
|
||||
from django.urls import resolve, reverse
|
||||
|
@ -7,9 +7,11 @@ from django.utils.safestring import mark_safe
|
|||
from django.utils.translation import gettext_lazy as _
|
||||
from django.views.generic import TemplateView
|
||||
from django.contrib import messages
|
||||
from api.tests.common import less_console_noise
|
||||
|
||||
from registrar.forms import application_wizard as forms
|
||||
from registrar.models import DomainApplication
|
||||
from registrar.tests.common import MockSESClient
|
||||
from registrar.utility import StrEnum
|
||||
from registrar.views.utility import StepsHelper
|
||||
|
||||
|
@ -569,6 +571,9 @@ class ApplicationWithdrawn(DomainApplicationPermissionWithdrawView):
|
|||
to withdraw and send back to homepage.
|
||||
"""
|
||||
application = DomainApplication.objects.get(id=self.kwargs["pk"])
|
||||
application.withdraw()
|
||||
application.save()
|
||||
mock_client = MockSESClient()
|
||||
with boto3_mocking.clients.handler_for("sesv2", mock_client):
|
||||
with less_console_noise():
|
||||
application.withdraw()
|
||||
application.save()
|
||||
return HttpResponseRedirect(reverse("home"))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue