Kaydet (Commit) 93f815a5 authored tarafından Martin Panter's avatar Martin Panter

Fix buggy RE “\parrot_example.py”, uncovered by Issue #27030

üst e52140ca
......@@ -8,6 +8,7 @@ import sys
import os
import codecs
import operator
import re
import StringIO
import tempfile
import shutil
......@@ -226,8 +227,8 @@ from __future__ import print_function"""
actually_write=False)
# Testing that it logged this message when write=False was passed is
# sufficient to see that it did not bail early after "No changes".
message_regex = r"Not writing changes to .*%s%s" % (
os.sep, os.path.basename(test_file))
message_regex = r"Not writing changes to .*%s" % \
re.escape(os.sep + os.path.basename(test_file))
for message in debug_messages:
if "Not writing changes" in message:
self.assertRegexpMatches(message, message_regex)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment