Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
9903c705
Commit
9903c705
authored
Feb 13, 2012
by
Gregory P. Smith
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
re.escape os.sep so that \ is interpreted properly in the regex.
parent
93b98ca4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
2 deletions
+3
-2
Lib/lib2to3/tests/test_main.py
Lib/lib2to3/tests/test_main.py
+3
-2
No files found.
Lib/lib2to3/tests/test_main.py
View file @
9903c705
...
...
@@ -94,10 +94,11 @@ class TestMain(unittest.TestCase):
self
.
assertIn
(
"Writing converted %s to %s"
%
(
os
.
path
.
join
(
self
.
py2_src_dir
,
name
),
os
.
path
.
join
(
self
.
py3_dest_dir
,
name
+
suffix
)),
stderr
)
sep
=
re
.
escape
(
os
.
sep
)
self
.
assertRegex
(
stderr
,
r"No changes to .*/__init__\
.py
".replace("
/
",
os.
sep))
stderr
,
r"No changes to .*/__init__\
.py
".replace("
/
", sep))
self.assertNotRegex(
stderr, r"
No
changes
to
.
*/
trivial
\
.
py
".replace("
/
",
os.
sep))
stderr, r"
No
changes
to
.
*/
trivial
\
.
py
".replace("
/
", sep))
def test_filename_changing_on_output_two_files(self):
"""2to3 two files in one directory with a new output dir."""
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment