mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-02-05 02:42:26 -05:00
110067722: Post add-service endpoint saves the service and maps it to the user.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
from app.main.dao import verify_codes_dao
|
||||
from app.main.dao import verify_codes_dao, services_dao
|
||||
from tests.app.main import create_test_user
|
||||
|
||||
|
||||
@@ -24,3 +24,5 @@ def test_should_add_service_and_redirect_to_next_page(notifications_admin, notif
|
||||
response = client.post('/add-service', data={'service_name': 'testing the post'})
|
||||
assert response.status_code == 302
|
||||
assert response.location == 'http://localhost/dashboard'
|
||||
saved_service = services_dao.find_service_by_service_name('testing the post')
|
||||
assert saved_service is not None
|
||||
|
||||
Reference in New Issue
Block a user