summaryrefslogtreecommitdiffstatshomepage
path: root/tests/basics/module_dict.py
blob: c847294f08916cf2aeb36119291a1ee86cc1cbc7 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
# test __dict__ attribute of a built-in module
# see import/module_dict.py for the equivalent test on user modules

import sys

if not hasattr(sys, "__dict__"):
    print("SKIP")
    raise SystemExit


# dict of a built-in module (read-only)
print(type(sys.__dict__))
print(sys.__dict__["__name__"])