Skip to content

Commit

Permalink
JeOS: small fix for image_info
Browse files Browse the repository at this point in the history
  • Loading branch information
jlausuch committed May 20, 2022
1 parent 88dc186 commit d30ea91
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions tests/jeos/image_info.pm
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ sub check_db {
}

# CASEDIR var is always set, and if when no specified, the value is "sle" for OSD and "opensuse" for O3
return if (get_required_var('CASEDIR') !~ m/^sle$|^opensuse$/);
return 0 if (get_required_var('CASEDIR') !~ m/^sle$|^opensuse$/);

my $openqa_host = get_required_var('OPENQA_HOSTNAME');
if ($openqa_host =~ /openqa1-opensuse|openqa.opensuse.org/) { # O3 hostname
Expand Down Expand Up @@ -177,8 +177,9 @@ sub run {
}

# Get the size of different file types
unless (is_openstack) {
my $btrfs_summary = script_output('btrfs filesystem df --mbytes --si /');
# This step applies to BTRFS images. For simplicity, others images will be skipped.
my $btrfs_summary = script_output('btrfs filesystem df --mbytes --si /', proceed_on_failure => 1);
if ($btrfs_summary !~ /ERROR/) {
record_info('btrfs', "$btrfs_summary");
my ($data) = $btrfs_summary =~ /Data.*/g;
my ($data_mb) = $data =~ /(\d+\.\d+)/g;
Expand Down

0 comments on commit d30ea91

Please sign in to comment.