MCPcopy
hub / github.com/tornadoweb/tornado / test_distinct_tokens

Method test_distinct_tokens

tornado/test/web_test.py:3009–3015  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

3007 self.assertEqual(response.code, 200)
3008
3009 def test_distinct_tokens(self):
3010 # Every request gets a distinct token.
3011 NUM_TOKENS = 10
3012 tokens = set()
3013 for i in range(NUM_TOKENS):
3014 tokens.add(self.get_token())
3015 self.assertEqual(len(tokens), NUM_TOKENS)
3016
3017 def test_cross_user(self):
3018 token2 = self.get_token()

Callers

nothing calls this directly

Calls 2

get_tokenMethod · 0.95
addMethod · 0.80

Tested by

no test coverage detected