[ SYSTEM ]: Linux srv.persadacompanies.com 4.18.0-553.56.1.el8_10.x86_64 #1 SMP Tue Jun 10 05:00:59 EDT 2025 x86_64
[ SERVER ]: Apache | PHP: 8.4.20
[ USER ]: persadamedika | IP: 45.64.1.108
GEFORCE FILE MANAGER
/
usr
/
share
/
doc
/
perl-Test-Simple
/
t
/
Legacy
/
subtest
/
UPLOAD:
NAME
SIZE
QUICK PERMS
ACTIONS
📄 args.t
620 B
SET
[ EDIT ]
|
[ DEL ]
📄 bail_out.t
1,280 B
SET
[ EDIT ]
|
[ DEL ]
📄 basic.t
4,812 B
SET
[ EDIT ]
|
[ DEL ]
📄 callback.t
1,016 B
SET
[ EDIT ]
|
[ DEL ]
📄 die.t
535 B
SET
[ EDIT ]
|
[ DEL ]
📄 do.t
283 B
SET
[ EDIT ]
|
[ DEL ]
📄 events.t
376 B
SET
[ EDIT ]
|
[ DEL ]
📄 for_do_t.test
112 B
SET
[ EDIT ]
|
[ DEL ]
📄 fork.t
1,228 B
SET
[ EDIT ]
|
[ DEL ]
📄 implicit_done.t
479 B
SET
[ EDIT ]
|
[ DEL ]
📄 line_numbers.t
3,858 B
SET
[ EDIT ]
|
[ DEL ]
📄 plan.t
1,377 B
SET
[ EDIT ]
|
[ DEL ]
📄 predicate.t
4,844 B
SET
[ EDIT ]
|
[ DEL ]
📄 singleton.t
712 B
SET
[ EDIT ]
|
[ DEL ]
📄 threads.t
430 B
SET
[ EDIT ]
|
[ DEL ]
📄 todo.t
5,462 B
SET
[ EDIT ]
|
[ DEL ]
📄 wstat.t
369 B
SET
[ EDIT ]
|
[ DEL ]
DELETE SELECTED
[ CLOSE ]
EDIT: fork.t
#!/usr/bin/perl -w use strict; use warnings; # HARNESS-NO-STREAM # HARNESS-NO-PRELOAD use Test2::Util qw/CAN_FORK/; BEGIN { unless(CAN_FORK) { require Test::More; Test::More->import(skip_all => "fork is not supported"); } } use IO::Pipe; use Test::Builder; use Test::More; plan 'skip_all' => "This test cannot be run with the current formatter" unless Test::Builder->new->{Stack}->top->format->isa('Test::Builder::Formatter'); plan 'tests' => 1; subtest 'fork within subtest' => sub { plan tests => 2; my $pipe = IO::Pipe->new; my $pid = fork; defined $pid or plan skip_all => "Fork not working"; if ($pid) { $pipe->reader; my $child_output = do { local $/ ; <$pipe> }; waitpid $pid, 0; is $?, 0, 'child exit status'; like $child_output, qr/^[\s#]+Child Done\s*\z/, 'child output'; } else { $pipe->writer; # Force all T::B output into the pipe, for the parent # builder as well as the current subtest builder. my $tb = Test::Builder->new; $tb->output($pipe); $tb->failure_output($pipe); $tb->todo_output($pipe); diag 'Child Done'; exit 0; } };