self.assertEqual(bytes(b"abc") < b"ab", False)
self.assertEqual(bytes(b"abc") <= b"ab", False)
+ @test.test_support.requires_docstrings
def test_doc(self):
self.assertIsNotNone(bytearray.__doc__)
self.assertTrue(bytearray.__doc__.startswith("bytearray("), bytearray.__doc__)
import time
import struct
import _testcapi
+import sysconfig
try:
import thread
except ImportError:
else:
return unittest.skip("resource {0!r} is not enabled".format(resource))
+requires_docstrings = unittest.skipUnless(
+ sysconfig.get_config_var('WITH_DOC_STRINGS'),
+ "test requires docstrings")
+
def cpython_only(test):
"""
Decorator for tests only applicable on CPython.