Skip to content

Commit 28317b8

Browse files
committed
Fix Deprecation warnings for escape sequences
1 parent 45436a0 commit 28317b8

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

tests/test_transcript.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -200,15 +200,15 @@ def test_history_transcript_bad_filename(request, capsys):
200200
( '/tmp is nice', re.escape('/tmp is nice') ),
201201
( 'slash at end/', re.escape('slash at end/') ),
202202
# escaped slashes
203-
( 'not this slash\/ or this one\/', re.escape('not this slash/ or this one/' ) ),
203+
( r'not this slash\/ or this one\/', re.escape('not this slash/ or this one/' ) ),
204204
# regexes
205205
( '/.*/', '.*' ),
206206
( 'specials ^ and + /[0-9]+/', re.escape('specials ^ and + ') + '[0-9]+' ),
207-
( '/a{6}/ but not \/a{6} with /.*?/ more', 'a{6}' + re.escape(' but not /a{6} with ') + '.*?' + re.escape(' more') ),
208-
( 'not \/, use /\|?/, not \/', re.escape('not /, use ') + '\|?' + re.escape(', not /') ),
207+
( r'/a{6}/ but not \/a{6} with /.*?/ more', 'a{6}' + re.escape(' but not /a{6} with ') + '.*?' + re.escape(' more') ),
208+
( r'not \/, use /\|?/, not \/', re.escape('not /, use ') + r'\|?' + re.escape(', not /') ),
209209
# inception: slashes in our regex. backslashed on input, bare on output
210-
( 'not \/, use /\/?/, not \/', re.escape('not /, use ') + '/?' + re.escape(', not /') ),
211-
( 'lots /\/?/ more /.*/ stuff', re.escape('lots ') + '/?' + re.escape(' more ') + '.*' + re.escape(' stuff') ),
210+
( r'not \/, use /\/?/, not \/', re.escape('not /, use ') + '/?' + re.escape(', not /') ),
211+
( r'lots /\/?/ more /.*/ stuff', re.escape('lots ') + '/?' + re.escape(' more ') + '.*' + re.escape(' stuff') ),
212212
])
213213
def test_parse_transcript_expected(expected, transformed):
214214
app = CmdLineApp()

0 commit comments

Comments
 (0)