Skip to content

Commit

Permalink
add test to make it fail
Browse files Browse the repository at this point in the history
  • Loading branch information
Glandos committed Jul 15, 2023
1 parent e61540d commit d09d19a
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions ihatemoney/tests/budget_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,16 @@ def test_invite(self):
resp = self.client.get("/raclette/join/token.invalid", follow_redirects=True)
self.assertIn("Provided token is invalid", resp.data.decode("utf-8"))

def test_create_should_remember_project(self):
"""Test that creating a project adds it to the "logged in project" list,
as it does for authentication
"""
self.login("raclette")
self.post_project("raclette")
self.post_project("tartiflette")
data = self.client.get("/raclette/").data.decode("utf-8")
self.assertEqual(data.count('href="/tartiflette/"'), 1)

def test_multiple_join(self):
"""Test that joining multiple times a project
doesn't add it multiple times in the session"""
Expand Down

0 comments on commit d09d19a

Please sign in to comment.