Commits

Andriy Kornatskyy  committed 2cdff73

Improved test_set_cookie test case.

  • Participants
  • Parent commits 2a6aef2

Comments (0)

Files changed (1)

File src/wheezy/http/tests/test_functional.py

         assert 1 == len(client.cookies)
         assert '12345' == client.cookies['c1']
 
+        # All cookies removed.
+        cookie = HTTPCookie.delete('c1', options=options)
+        response.cookies.append(cookie)
+        assert 200 == client.get('/abc')
+        assert 0 == len(client.cookies)
+        assert 'HTTP_COOKIE' in client.environ
+        assert 200 == client.get('/abc')
+        assert 'HTTP_COOKIE' not in client.environ
+
 
 class FormTestCase(unittest.TestCase):
     """ Test the ``Form`` class.