Skip to content

Commit

Permalink
[TODO FUDGE] LAST phaser gets triggered when using -n command line sw…
Browse files Browse the repository at this point in the history
…itch

RT#128398
  • Loading branch information
zoffixznet committed Jul 14, 2016
1 parent bf10b7b commit ca52ecc
Showing 1 changed file with 17 additions and 1 deletion.
18 changes: 17 additions & 1 deletion S29-os/system.t
Expand Up @@ -8,7 +8,7 @@ use Test::Util;
# L<S29/"OS"/"=item run">
# system is renamed to run, so link there.

plan 30;
plan 31;

my $res;

Expand Down Expand Up @@ -83,6 +83,22 @@ throws-like { shell("program_that_does_not_exist_ignore_errors_please.exe") },
}
}

# RT #128398
{
my $p = Proc::Async.new: :w, $*EXECUTABLE, "-ne",
Q!last if /2/; .say; LAST { say "test worked" }!;

my $stdout = '';
$p.stdout.tap: { $stdout ~= $^a };
my $prom = $p.start;
await $p.write: "1\n2\n3\n4\n".encode;
await $prom;

#?rakudo.moar todo 'RT 128398'
is $stdout, "1\ntest worked\n",
'LAST phaser gets triggered when using -n command line switch';
}

# all these tests feel like bogus, what are we testing here???
# note: is_run fails after these tests because we are no longer in the right dir
chdir "t";
Expand Down

0 comments on commit ca52ecc

Please sign in to comment.