summaryrefslogtreecommitdiff
path: root/Lib/test/test_compileall.py
diff options
context:
space:
mode:
authorR David Murray <rdmurray@bitdance.com>2015-12-04 22:54:38 -0500
committerR David Murray <rdmurray@bitdance.com>2015-12-04 22:54:38 -0500
commitced699b4c7e79e0a53e3ca7f2d789b761d4a9e76 (patch)
tree6d129c7f79a8dccd49a65adbb57b45f075b3d98b /Lib/test/test_compileall.py
parentafdd51343cafbc02443fa6f7a2166af951a67c64 (diff)
downloadcpython-git-ced699b4c7e79e0a53e3ca7f2d789b761d4a9e76.tar.gz
#24903: Remove misleading error message to fix regression.
Before the argparse conversion, compileall would (sometimes) accept multiple paths when -d was specified. Afterward, it does not. The corresponding check in the original code claimed to prevent multiple *directories* from being specified...but it didn't really work even to do that. So this patch fixes the regression by invoking the consenting adults rule: if you specify a combination of arguments to compileall that produces files with inconsistent destdirs (which you could do before), it is on you. Patch by Jake Garver.
Diffstat (limited to 'Lib/test/test_compileall.py')
-rw-r--r--Lib/test/test_compileall.py8
1 files changed, 0 insertions, 8 deletions
diff --git a/Lib/test/test_compileall.py b/Lib/test/test_compileall.py
index 7b307edfbc..7c61fa3250 100644
--- a/Lib/test/test_compileall.py
+++ b/Lib/test/test_compileall.py
@@ -323,14 +323,6 @@ class CommandLineTests(unittest.TestCase):
self.assertCompiled(init2fn)
self.assertCompiled(bar2fn)
- def test_d_takes_exactly_one_dir(self):
- rc, out, err = self.assertRunNotOK('-d', 'foo')
- self.assertEqual(out, b'')
- self.assertRegex(err, b'-d')
- rc, out, err = self.assertRunNotOK('-d', 'foo', 'bar')
- self.assertEqual(out, b'')
- self.assertRegex(err, b'-d')
-
def test_d_compile_error(self):
script_helper.make_script(self.pkgdir, 'crunchyfrog', 'bad(syntax')
rc, out, err = self.assertRunNotOK('-q', '-d', 'dinsdale', self.pkgdir)