Correct 3.7 "impor"t and "from .. import"

This commit is contained in:
rocky
2022-04-20 20:03:28 -04:00
parent e2ff909603
commit c88d9de316
7 changed files with 80 additions and 26 deletions

Binary file not shown.

Binary file not shown.

View File

@@ -1,11 +1,23 @@
# Tests all the different kinds of imports
"""This program is self-checking!"""
import sys
from os import path
from os import *
from os import * # NOQA
import time as time1, os as os1
import http.client as httpclient
from sys import stdin, stdout, stderr
assert isinstance(os1.pathsep, str)
assert time1.time() > 0
import os.path as osp
assert osp == path
from os.path import join as jj
assert path.join == jj
if len(__file__) == 0:
# a.b.c should force consecutive LOAD_ATTRs
import a.b.c as d
import stuff0.stuff1.stuff2.stuff3 as stuff3
sys.exit(0)