2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2026-09-04 12:07:56 +00:00

test(genesis): use explicit fractional sleep

Signed-off-by: Vinícius Ferrão <2031761+viniciusferrao@users.noreply.github.com>
This commit is contained in:
Vinícius Ferrão
2026-08-25 00:36:00 -03:00
parent a983faf736
commit 9edbbc1817
+3 -2
View File
@@ -6,6 +6,7 @@ use File::Path qw(make_path);
use File::Temp qw(tempdir);
use FindBin;
use Test::More;
use Time::HiRes qw(sleep);
BEGIN {
$ENV{XCATROOT} = "$FindBin::Bin/../../xCAT-server";
@@ -31,7 +32,7 @@ my $kernel = "$tftp/xcat/genesis.kernel.x86_64";
my $lzma = "$tftp/xcat/genesis.fs.x86_64.lzma";
my $gzip = "$tftp/xcat/genesis.fs.x86_64.gz";
write_file($_) for ($kernel, $lzma);
select(undef, undef, undef, 1.1);
sleep(1.1);
write_file($gzip);
my ($selected_kernel, $selected_initrd) =
@@ -41,7 +42,7 @@ is($selected_kernel, 'genesis.kernel.x86_64',
is($selected_initrd, 'genesis.fs.x86_64.gz',
'SLES selects the newer gzip initramfs');
select(undef, undef, undef, 1.1);
sleep(1.1);
write_file($lzma);
($selected_kernel, $selected_initrd) =
xCAT_plugin::sles::_find_genesis_boot_files($tftp, 'x86_64');