MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_isspace_invariant

Method test_isspace_invariant

Lib/test/test_str.py:745–752  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

743
744 @support.requires_resource('cpu')
745 def test_isspace_invariant(self):
746 for codepoint in range(sys.maxunicode + 1):
747 char = chr(codepoint)
748 bidirectional = unicodedata.bidirectional(char)
749 category = unicodedata.category(char)
750 self.assertEqual(char.isspace(),
751 (bidirectional in ('WS', 'B', 'S')
752 or category == 'Zs'))
753
754 def test_isalnum(self):
755 super().test_isalnum()

Callers

nothing calls this directly

Calls 5

chrFunction · 0.85
bidirectionalMethod · 0.80
categoryMethod · 0.80
assertEqualMethod · 0.45
isspaceMethod · 0.45

Tested by

no test coverage detected