7 skip_rest "Programs running in browsers don't have access to regular IO.";
14 sub nonce () { return (".{$*PID}." ~ (1..1000).pick) }
16 sub run_test ($args) {
17 my $out_fn = "temp-ex-output" ~ nonce;
18 my $command = "$*EXECUTABLE_NAME $args $redir $out_fn";
21 my $expected = "Unrecognized switch: -foo (-h will show valid options).\n";
22 my $got = chomp( slurp $out_fn );
27 is run_test("t/run/dump_params.pl 1"), ("1",).perl, " bare arg works";
28 is run_test("t/run/dump_params.pl --n"), ("--n",).perl, " --n arg works";
29 for (qw/n p c e h V v/) {
30 is run_test("t/run/dump_params.pl -$_"), ("-$_",).perl, " -$_ arg works";
32 is run_test("t/run/dump_params.pl -a"), ('-a',).perl, " -a arg works";