eradicate Term records after testing them

Otherwise, Terms can leak out into other tests causing /tos
redirects unexpectedly.

Signed-off-by: Kevin Morris <kevr@0cost.org>
This commit is contained in:
Kevin Morris 2021-06-24 19:50:42 -07:00
parent adb42882c5
commit a36cc0c00a
3 changed files with 16 additions and 0 deletions

View file

@ -58,6 +58,12 @@ def setup():
RealName="Test User", Passwd="testPassword",
AccountType=account_type)
yield user
# Remove term records so other tests don't get them
# and falsely redirect.
setup_test_db("Terms", "AcceptedTerms")
def test_get_passreset_authed_redirects():
sid = user.login(Request(), "testPassword")