tests/getpart: generate output URL encoded for better diffs
Closes #7083
This commit is contained in:
parent
d845d392b5
commit
1f90d08371
@ -5,7 +5,7 @@
|
|||||||
# | (__| |_| | _ <| |___
|
# | (__| |_| | _ <| |___
|
||||||
# \___|\___/|_| \_\_____|
|
# \___|\___/|_| \_\_____|
|
||||||
#
|
#
|
||||||
# Copyright (C) 1998 - 2020, Daniel Stenberg, <daniel@haxx.se>, et al.
|
# Copyright (C) 1998 - 2021, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
#
|
#
|
||||||
# This software is licensed as described in the file COPYING, which
|
# This software is licensed as described in the file COPYING, which
|
||||||
# you should have received as part of this distribution. The terms
|
# you should have received as part of this distribution. The terms
|
||||||
@ -313,6 +313,7 @@ sub showdiff {
|
|||||||
my $l = $_;
|
my $l = $_;
|
||||||
$l =~ s/\r/[CR]/g;
|
$l =~ s/\r/[CR]/g;
|
||||||
$l =~ s/\n/[LF]/g;
|
$l =~ s/\n/[LF]/g;
|
||||||
|
$l =~ s/([^\x20-\x7f])/sprintf "%%%02x", ord $1/eg;
|
||||||
print TEMP $l;
|
print TEMP $l;
|
||||||
print TEMP "\n";
|
print TEMP "\n";
|
||||||
}
|
}
|
||||||
@ -323,6 +324,7 @@ sub showdiff {
|
|||||||
my $l = $_;
|
my $l = $_;
|
||||||
$l =~ s/\r/[CR]/g;
|
$l =~ s/\r/[CR]/g;
|
||||||
$l =~ s/\n/[LF]/g;
|
$l =~ s/\n/[LF]/g;
|
||||||
|
$l =~ s/([^\x20-\x7f])/sprintf "%%%02x", ord $1/eg;
|
||||||
print TEMP $l;
|
print TEMP $l;
|
||||||
print TEMP "\n";
|
print TEMP "\n";
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user