Skip to content

Commit

Permalink
fix(maxitwit_test.py): make tests great again!
Browse files Browse the repository at this point in the history
  • Loading branch information
benceluzsinszky committed Apr 12, 2024
1 parent 13f8b4a commit 22474c0
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions tests/maxitwit_test.py
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
# -*- coding: utf-8 -*-
"""
MiniTwit Tests
~~~~~~~~~~~~~~
MiniTwit Tests
~~~~~~~~~~~~~~
Tests a MiniTwit application.
Tests a MiniTwit application.
:refactored: (c) 2024 by HelgeCPH from Armin Ronacher's original unittest version
:copyright: (c) 2010 by Armin Ronacher.
:license: BSD, see LICENSE for more details.
:refactored: (c) 2024 by HelgeCPH from Armin Ronacher's original unittest version
:copyright: (c) 2010 by Armin Ronacher.
:license: BSD, see LICENSE for more details.
"""

import requests
import json
import base64
Expand Down Expand Up @@ -274,7 +275,8 @@ def test_api_a_unfollows_b():
query = {"no": 20, "latest": 11}
response = requests.get(url, params=query, headers=HEADERS)
assert response.ok
assert "b" not in response.json()["follows"]
assert "[email protected]" not in response.json()["follows"]
assert "[email protected]" in response.json()["follows"]

# verify that latest was updated
response = requests.get(f"{API_URL}:{API_PORT}/latest", headers=HEADERS)
Expand Down

0 comments on commit 22474c0

Please sign in to comment.