mirror of
https://github.com/micropython/micropython.git
synced 2026-01-05 11:40:18 +01:00
17 lines
222 B
Python
17 lines
222 B
Python
# tests that import only sets subpackage attribute on first import
|
|
|
|
import pkg9
|
|
|
|
pkg9.mod1()
|
|
pkg9.mod2()
|
|
|
|
import pkg9.mod1
|
|
|
|
pkg9.mod1()
|
|
pkg9.mod2()
|
|
|
|
import pkg9.mod2
|
|
|
|
pkg9.mod1()
|
|
print(pkg9.mod2.__name__, type(pkg9.mod2))
|