Commit e5a6a263 authored by Paul Sokolovsky's avatar Paul Sokolovsky
Browse files

tests/types1: Split out set type test to set_types.

set isn't the most basic type and can be disabled by a port.
parent 36ec5c8f
# set type
# This doesn't really work as expected, because {None}
# leads SyntaxError during parsing.
try:
set
except NameError:
import sys
print("SKIP")
sys.exit()
print(set)
print(type(set()) == set)
print(type({None}) == set)
# basic types
# similar test for set type is done in set_type.py
print(bool)
print(int)
print(tuple)
print(list)
print(set)
print(dict)
print(type(bool()) == bool)
print(type(int()) == int)
print(type(tuple()) == tuple)
print(type(list()) == list)
print(type(set()) == set)
print(type(dict()) == dict)
print(type(False) == bool)
print(type(0) == int)
print(type(()) == tuple)
print(type([]) == list)
print(type({None}) == set)
print(type({}) == dict)
try:
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment