2 # Copyright (C) 2007, Parrot Foundation.
4 # 02-get_test_prog_args.t
12 use Parrot::Config qw( %PConfig );
14 plan( skip_all => 't/harness only runs once configuration has completed' )
18 use Parrot::Harness::Options qw( get_test_prog_args );
21 my ($gc_debug, $run_exec);
28 ($gc_debug, $run_exec) = (0,0);
29 $args = get_test_prog_args($optsref, $gc_debug, $run_exec);
30 like($args, qr/-d/, "Got expected option");
31 like($args, qr/-D40/, "Got expected option");
39 ($gc_debug, $run_exec) = (0,0);
40 $args = get_test_prog_args($optsref, $gc_debug, $run_exec);
41 like($args, qr/-d/, "Got expected option");
42 like($args, qr/-D40/, "Got expected option");
43 like($args, qr/-O2/, "Got expected option");
50 ($gc_debug, $run_exec) = (1,0);
51 $args = get_test_prog_args($optsref, $gc_debug, $run_exec);
52 like($args, qr/-d/, "Got expected option");
53 like($args, qr/-D40/, "Got expected option");
54 like($args, qr/\s--gc-debug/, "Got expected option");
61 ($gc_debug, $run_exec) = (0,1);
62 $args = get_test_prog_args($optsref, $gc_debug, $run_exec);
63 like($args, qr/-d/, "Got expected option");
64 like($args, qr/-D40/, "Got expected option");
65 like($args, qr/\s--run-exec/, "Got expected option");
67 pass("Completed all tests in $0");
69 ################### DOCUMENTATION ###################
73 02-get_test_prog_args.t - test Parrot::Harness::Options
77 % prove t/pharness/02-get_test_prog_args.t
81 This file holds tests for Parrot::Harness::Options::get_test_prog_args().
89 Parrot::Harness::Options, F<t/harness>.
95 # cperl-indent-level: 4
98 # vim: expandtab shiftwidth=4: