This is a live mirror of the Perl 5 development currently hosted at
https://github.com/perl/perl5
https://perl5.git.perl.org
/
perl5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
ceea523
)
t/re/pat_advanced.t: Fix test to work on EBCDIC
author
Karl Williamson
<khw@cpan.org>
Tue, 11 Jul 2017 02:11:09 +0000
(20:11 -0600)
committer
Karl Williamson
<khw@cpan.org>
Tue, 11 Jul 2017 02:20:09 +0000
(20:20 -0600)
t/re/pat_advanced.t
patch
|
blob
|
blame
|
history
diff --git
a/t/re/pat_advanced.t
b/t/re/pat_advanced.t
index
a2ff681
..
3d57bea
100644
(file)
--- a/
t/re/pat_advanced.t
+++ b/
t/re/pat_advanced.t
@@
-945,7
+945,9
@@
sub run_tests {
'Empty string charname produces NOTHING node';
like "\N{LONG-STR}", qr/^\N{LONG-STR}$/, 'Verify that long string works';
like "\N{LONG-STR}", qr/^\N{LONG-STR}$/i, 'Verify under folding that long string works';
'Empty string charname produces NOTHING node';
like "\N{LONG-STR}", qr/^\N{LONG-STR}$/, 'Verify that long string works';
like "\N{LONG-STR}", qr/^\N{LONG-STR}$/i, 'Verify under folding that long string works';
- like "\xc4", qr/\N{EMPTY-STR}\xe4/i, 'Empty \N{} should change /d to /u';
+
+ # perlhacktips points out that these work on both ASCII and EBCDIC
+ like "\xfc", qr/\N{EMPTY-STR}\xdc/i, 'Empty \N{} should change /d to /u';
eval '/(?[[\N{EMPTY-STR}]])/';
like $@, qr/Zero length \\N\{\}/, 'Verify zero-length return from \N{} correctly fails';
eval '/(?[[\N{EMPTY-STR}]])/';
like $@, qr/Zero length \\N\{\}/, 'Verify zero-length return from \N{} correctly fails';