Lines Matching refs:altchars
141 eq(base64.b64encode(b'\xd3V\xbeo\xf7\x1d', altchars=b'*$'), b'01a*b$cd')
142 eq(base64.b64encode(b'\xd3V\xbeo\xf7\x1d', altchars=bytearray(b'*$')),
144 eq(base64.b64encode(b'\xd3V\xbeo\xf7\x1d', altchars=memoryview(b'*$')),
146 eq(base64.b64encode(b'\xd3V\xbeo\xf7\x1d', altchars=array('B', b'*$')),
151 self.assertRaises(TypeError, base64.b64encode, b"", altchars="*$")
202 for (data, altchars), res in tests_altchars.items():
204 altchars_str = altchars.decode('ascii')
206 eq(base64.b64decode(data, altchars=altchars), res)
207 eq(base64.b64decode(data_str, altchars=altchars), res)
208 eq(base64.b64decode(data, altchars=altchars_str), res)
209 eq(base64.b64decode(data_str, altchars=altchars_str), res)