MCPcopy Create free account
hub / github.com/davidaurelio/hashids-python / test_all_parameters

Method test_all_parameters

test/test_hashids.py:63–68  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

61 assert h.encode(99, 25) == 'k91nqP3RBe3lKfDaLJrvy8XjV'
62
63 def test_all_parameters(self):
64 h = Hashids('arbitrary salt', 16, 'abcdefghijklmnopqrstuvwxyz')
65 assert h.encode(7452, 2967, 21401) == 'wygqxeunkatjgkrw'
66 assert h.encode(1, 2, 3) == 'pnovxlaxuriowydb'
67 assert h.encode(60125) == 'jkbgxljrjxmlaonp'
68 assert h.encode(99, 25) == 'erdjpwrgouoxlvbx'
69
70 def test_alphabet_without_standard_separators(self):
71 h = Hashids(alphabet='abdegjklmnopqrvwxyzABDEGJKLMNOPQRVWXYZ1234567890')

Callers

nothing calls this directly

Calls 2

encodeMethod · 0.95
HashidsClass · 0.90

Tested by

no test coverage detected