Advanced-Config
view release on metacpan or search on metacpan
t/60-recursion-test.t view on Meta::CPAN
};
if ( $@ ) {
unless (defined $cfg) {
dbug_isa_ok ($cfg, 'Advanced::Config');
}
dbug_ok (0, "Advanced::Config contents have been loaded into memory!");
DBUG_LEAVE (3);
}
my $val = $cfg->get_value ("recursion");
dbug_ok ( (defined $val && $val eq "OK"), "Recursion was blocked!");
$val = $cfg->get_value ("recursion2");
dbug_ok ( (defined $val && $val eq " OK"), "Recursion2 was blocked!");
# Since I didn't count the test cases, must end my program
# with a call to this method. Can't do tests in END anymore!
done_testing ();
DBUG_LEAVE (0);
}
# ====================================================================
t/config/60-recursion-test.cfg view on Meta::CPAN
. 50-merge_d.cfg
. 50-merge_c.cfg
# Recursion should fail!!!
. ../config/60-recursion-test.cfg
# OK to repeat again ...
. ../config/50-merge_d.cfg
# Used to detect how many times recursion worked!
recursion = ${recursion} OK # Value is "OK" if recursion was blocked!
recursion2 = '${recursion2} OK' # Value is " OK" if recursion was blocked!
# ---------------------------------------------------------------------------
( run in 0.540 second using v1.01-cache-2.11-cpan-49f99fa48dc )