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

Method test_rjust

Lib/test/test_bytes.py:897–902  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

895 self.type2test(b'abc----'))
896
897 def test_rjust(self):
898 # Fill character can be either bytes or bytearray (issue 12380)
899 b = self.type2test(b'abc')
900 for fill_type in (bytes, bytearray):
901 self.assertEqual(b.rjust(7, fill_type(b'-')),
902 self.type2test(b'----abc'))
903
904 def test_xjust_int_error(self):
905 self.assertRaises(TypeError, self.type2test(b'abc').center, 7, 32)

Callers

nothing calls this directly

Calls 3

type2testMethod · 0.80
assertEqualMethod · 0.45
rjustMethod · 0.45

Tested by

no test coverage detected