2 # Copyright (C) 2009, Parrot Foundation.
7 use Test::More tests => 8;
9 use lib qw( lib t/configure/testlib );
10 use_ok('config::auto::thread');
11 use Parrot::Configure::Options qw( process_options );
12 use Parrot::Configure::Step::Test;
13 use Parrot::Configure::Test qw(
14 test_step_constructor_and_description
17 ########## --without-threads ##########
19 my ($args, $step_list_ref) = process_options(
21 argv => [ q{--without-threads} ],
26 my $conf = Parrot::Configure::Step::Test->new;
27 $conf->include_config_results( $args );
29 my $pkg = q{auto::thread};
31 $conf->add_steps($pkg);
33 my $serialized = $conf->pcfreeze();
35 $conf->options->set( %{$args} );
36 my $step = test_step_constructor_and_description($conf);
37 my $ret = $step->runstep($conf);
38 ok( $ret, "runstep() returned true value" );
39 is($conf->data->get('HAS_THREADS'), 0,
40 "Got expected value for 'HAS_THREADS'");
41 is($step->result(), q{no}, "Expected result was set");
43 $conf->replenish($serialized);
45 pass("Completed all tests in $0");
47 ################### DOCUMENTATION ###################
51 auto/thread-01.t - test auto::thread
55 % prove t/steps/auto/thread-01.t
59 The files in this directory test functionality used by F<Configure.pl>.
61 The tests in this file test auto::thread.
65 Mostly taken from F<t/steps/auto_gdbm-01.t>.
73 config::auto::thread, F<Configure.pl>.
79 # cperl-indent-level: 4
82 # vim: expandtab shiftwidth=4: