circuitpython/tests/basics/del_name.py
Damien George 12c66be2b8 tests: Add some tests to improve coverage.
Used gcov to find some parts of vm.c, runtime.c, obj.c that were not
covered by any tests.  Still need to use gcov more thoroughly.
2015-01-29 00:44:11 +00:00

19 lines
229 B
Python

# del name
x = 1
print(x)
del x
try:
print(x)
except NameError:
print("NameError")
try:
del x
except: # NameError:
# FIXME uPy returns KeyError for this
print("NameError")
class C:
def f():
pass