From 2c416f97c749d35ba68dfbb5b9c44042de1430b3 Mon Sep 17 00:00:00 2001 From: Noah Misch Date: Fri, 1 Mar 2024 15:04:36 -0800 Subject: [PATCH] reorder to before SKIP --- t/eintr.t | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/t/eintr.t b/t/eintr.t index 6623d27..8f539f8 100644 --- a/t/eintr.t +++ b/t/eintr.t @@ -10,7 +10,6 @@ eintr.t - Test select() failing with EINTR use strict; use warnings; -use Time::HiRes qw(gettimeofday tv_interval); BEGIN { $| = 1; @@ -25,6 +24,14 @@ BEGIN { use Test::More; use IPC::Run qw( start run ); +use Time::HiRes qw(gettimeofday tv_interval); +for my $v (0, 1) { + local $ENV{SIG_WORKAROUND_SUPPRESS} = $v; + my $before = [gettimeofday]; + run([qw(sleep 0.7)]); + diag 'duration: ' . tv_interval($before, [gettimeofday]); +} + my $got_usr1 = 0; $SIG{USR1} = sub { $got_usr1++ }; @@ -60,10 +67,3 @@ is $got_usr1, 2, 'got USR1 from the kid'; $harness->kill_kill; $harness->finish; - -for my $v (0, 1) { - local $ENV{SIG_WORKAROUND_SUPPRESS} = $v; - my $before = [gettimeofday]; - run([qw(sleep 0.7)]); - diag 'duration: ' . tv_interval($before, [gettimeofday]); -}