summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_file.py
diff options
context:
space:
mode:
authorRobert Collins <rbtcollins@hp.com>2015-07-25 18:43:13 (GMT)
committerRobert Collins <rbtcollins@hp.com>2015-07-25 18:43:13 (GMT)
commitc94a1dc4c9a5d23fdb21f6928dd737a59ef3dfb2 (patch)
treeabbbf37e11a6ba307ba00eaa2cf40e27d62d09d2 /Lib/test/test_file.py
parent882667203ca638ffce4238740c521c2a8320be09 (diff)
downloadcpython-c94a1dc4c9a5d23fdb21f6928dd737a59ef3dfb2.zip
cpython-c94a1dc4c9a5d23fdb21f6928dd737a59ef3dfb2.tar.gz
cpython-c94a1dc4c9a5d23fdb21f6928dd737a59ef3dfb2.tar.bz2
- Issue #2091: error correctly on open() with mode 'U' and '+'
open() accepted a 'U' mode string containing '+', but 'U' can only be used with 'r'. Patch from Jeff Balogh and John O'Connor.
Diffstat (limited to 'Lib/test/test_file.py')
-rw-r--r--Lib/test/test_file.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/test/test_file.py b/Lib/test/test_file.py
index d54e976..94f189a 100644
--- a/Lib/test/test_file.py
+++ b/Lib/test/test_file.py
@@ -139,7 +139,7 @@ class OtherFileTests:
def testModeStrings(self):
# check invalid mode strings
- for mode in ("", "aU", "wU+"):
+ for mode in ("", "aU", "wU+", "U+", "+U", "rU+"):
try:
f = self.open(TESTFN, mode)
except ValueError: