mirror of
https://github.com/GSA/notifications-api.git
synced 2026-02-05 18:52:50 -05:00
update letter tests to use correct service
previously they were using sample_service fixture under the hood, but with full permissions added - this works fine, **unless** there's already a service with the name "sample service" in the database. This can happen for two reasons: * A previous test didn't tear down correctly * This test already invoked the sample_service fixture somehow If this happens, we just return the existing service, without modifying its values - values that we might change in tests, such as research mode or letters permissions. In the future, we'll have to be vigilant! and aware! and careful! to not use sample_service if we're doing tests involving letters, since they create a service with a different name now
This commit is contained in:
@@ -31,5 +31,5 @@ pycodestyle .
|
||||
display_result $? 1 "Code style check"
|
||||
|
||||
# run with four concurrent threads
|
||||
py.test --cov=app --cov-report=term-missing tests/ --junitxml=test_results.xml -n 4
|
||||
py.test --cov=app --cov-report=term-missing tests/ --junitxml=test_results.xml -n 4 -v
|
||||
display_result $? 2 "Unit tests"
|
||||
|
||||
Reference in New Issue
Block a user