1 use Test::More no_plan => 1;
3 use Test::MooseX::Daemonize;
6 my $Test = Test::Builder->new;
12 with qw(MooseX::Daemonize);
13 with qw(Test::MooseX::Daemonize::Testable); # setup our test environment
25 $Test->ok( $count++, "$count output_ok" );
36 use File::Spec::Functions;
37 use File::Temp qw(tempdir);
39 my $dir = tempdir( CLEANUP => 1 );
41 ## Try to make sure we are in the test directory
42 my $app = TestOutput->new(
44 test_output => catfile($dir, 'results'),
46 daemonize_ok( $app, 'child forked okay' );
47 sleep(3); # give ourself a chance to produce some output
51 local $SIG{__WARN__} = sub { $warnings .= $_[0]; warn @_ };
52 $app->stop( no_exit => 1 );
55 is($warnings, "", "No warnings from stop");
57 check_test_output($app);
58 unlink( $app->test_output );