Files
RustPython/tests/snippets/builtin_hex.py
2018-10-27 19:33:04 -03:00

10 lines
177 B
Python

assert hex(16) == '0x10'
assert hex(-16) == '-0x10'
try:
hex({})
except TypeError:
pass
else:
assert False, "TypeError not raised when ord() is called with a dict"