Added session to be part of state.

This commit is contained in:
2024-03-19 19:54:14 -04:00
parent 0b076aac12
commit ba41b311ab
3 changed files with 143 additions and 12 deletions

View File

@ -74,3 +74,14 @@ class BootUpTC(MTTClusterTC):
for _ in range(2):
await self.run_tests("/", tests)
self.assertEqual(len(ids), 1)
async def test_reset_bad_session_id(self):
"""Does the session id get reset if bad or expired?"""
await self.create_server()
value = "bad id"
async with ClientSession() as session:
async with session.get(
f"{self.servers[0].host}/", cookies={SESSION_KEY: value}
) as response:
self.assertIn(SESSION_KEY, response.cookies)
self.assertNotEqual(response.cookies[SESSION_KEY].value, value)