Skip to content

Commit a53b949

Browse files
committed
t/run/switches.t: touch up -s section
- move "bug id" comment where it was originally placed: before the "#!perl -s" test - add GH ticket number and short description - remove 2-arg open
1 parent ed152e1 commit a53b949

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

t/run/switches.t

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -155,9 +155,10 @@ $r = runperl(
155155
);
156156
is( $r, '21-', '-s switch parsing' );
157157

158+
# Bug ID 20011106.084 (RT #7876 / GH #4554): -s on shebang line
158159
$filename = tempfile();
159160
SKIP: {
160-
open my $f, ">$filename" or skip( "Can't write temp file $filename: $!" );
161+
open my $f, ">", $filename or skip( "Can't write temp file $filename: $!" );
161162
print $f <<'SWTEST';
162163
#!perl -s
163164
BEGIN { print $x,$y; exit }
@@ -170,10 +171,9 @@ SWTEST
170171
is( $r, 'foo1', '-s on the shebang line' );
171172
}
172173

173-
# Bug ID 20011106.084 (#7876)
174174
$filename = tempfile();
175175
SKIP: {
176-
open my $f, ">$filename" or skip( "Can't write temp file $filename: $!" );
176+
open my $f, ">", $filename or skip( "Can't write temp file $filename: $!" );
177177
print $f <<'SWTEST';
178178
#!perl -sn
179179
BEGIN { print $x; exit }

0 commit comments

Comments
 (0)