summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorTim Peters <tim.peters@gmail.com>2001-03-21 03:58:16 (GMT)
committerTim Peters <tim.peters@gmail.com>2001-03-21 03:58:16 (GMT)
commiteba5130e4f3254e5722b09421224cd86d6d9aca8 (patch)
treee1c6f02a9aec8dd05044182ff851662e434a11ce /Lib
parent9de05f4157e4bb2f66b44635eaee840dc9d79ce8 (diff)
downloadcpython-eba5130e4f3254e5722b09421224cd86d6d9aca8.zip
cpython-eba5130e4f3254e5722b09421224cd86d6d9aca8.tar.gz
cpython-eba5130e4f3254e5722b09421224cd86d6d9aca8.tar.bz2
Addrf simple test that import is case-sensitive.
Diffstat (limited to 'Lib')
-rw-r--r--Lib/test/test_import.py11
1 files changed, 10 insertions, 1 deletions
diff --git a/Lib/test/test_import.py b/Lib/test/test_import.py
index 9c2f16f..a151def 100644
--- a/Lib/test/test_import.py
+++ b/Lib/test/test_import.py
@@ -1,9 +1,18 @@
-from test_support import TESTFN
+from test_support import TESTFN, TestFailed
import os
import random
import sys
+# Brief digression to test that import is case-sensitive: if we got this
+# far, we know for sure that "random" exists.
+try:
+ import RAnDoM
+except ImportError:
+ pass
+else:
+ raise TestFailed("import of RAnDoM should have failed (case mismatch)")
+
sys.path.insert(0, os.curdir)
source = TESTFN + ".py"