new apps.lyric.views login FBV; new login path in .urls; new UT in .tests.test_views to assert the FBV's redirect to '/'

This commit is contained in:
Disco DeDisco
2026-01-30 17:36:48 -05:00
parent 93eb497dec
commit bab0b045b0
3 changed files with 10 additions and 0 deletions

View File

@@ -33,3 +33,8 @@ class SendLoginEmailViewTest(TestCase):
"Check your email!—there you'll find a magic login link. But hurry… it's only temporary!",
)
self.assertEqual(message.tags, "success")
class LoginViewTest(TestCase):
def test_redirects_to_home_page(self):
response = self.client.get("/apps/lyric/login?token=abc123")
self.assertRedirects(response, "/")