Skip to content

Commit

Permalink
CLI: Support lower-case test argument passing
Browse files Browse the repository at this point in the history
isotovideo from os-autoinst already automatically transforms lower-case
test parameter command line arguments into upper-case test arguments.
openQA so far only checked the validity of upper-case parameters in a
regex. Instead we can just support supplied lower-ase test parameter
command line arguments as well by just ensuring all arguments are
upper-cased.
  • Loading branch information
okurz committed Mar 16, 2023
1 parent 8a49082 commit cf804f6
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/OpenQA/Command.pm
Original file line number Diff line number Diff line change
Expand Up @@ -75,11 +75,13 @@ sub parse_headers ($self, @headers) {
sub parse_params ($self, $args, $param_file) {
my %params;
for my $arg (@{$args}) {
$arg = uc $arg;
next unless $arg =~ $PARAM_RE;
push @{$params{$1}}, $2;
}

for my $arg (@{$param_file}) {
$arg = uc $arg;
next unless $arg =~ $PARAM_RE;
push @{$params{$1}}, path($2)->slurp;
}
Expand Down

0 comments on commit cf804f6

Please sign in to comment.