diff --git a/cicd/testbed_poll.pl b/cicd/testbed_poll.pl index f53c1b3b9..13ceb712c 100755 --- a/cicd/testbed_poll.pl +++ b/cicd/testbed_poll.pl @@ -75,6 +75,24 @@ my $cmd = "curl $cuser $url"; print ("Calling command: $cmd\n"); my $listing = do_system($cmd); my @lines = split(/\n/, $listing); + +# First, if any have 'fast' in them, they get precedence. +for ($i = 0; $i<@lines; $i++) { + my $ln = $lines[$i]; + chomp($ln); + my $fast = 0; + if ($ln =~ /href=\"(CICD_TEST-.*-fast)\">(.*)<\/a>\s+(.*)\s+\S+\s+\S+/) { + $fast = 1; + } + elsif ($ln =~ /href=\"(CICD_TEST-.*-fast)\">(.*)<\/a>/) { + $fast = 1; + } + if ($fast) { + @lines[0] = $ln; + last; + } +} + for ($i = 0; $i<@lines; $i++) { my $ln = $lines[$i]; chomp($ln); @@ -150,6 +168,11 @@ for ($i = 0; $i<@lines; $i++) { exit(1); } + # Refresh wlan-ap repo if it exists. + if ( -d "../../../wlan-ap") { + do_system("cd ../../../wlan-ap && git pull && cd -"); + } + my $cmd = "curl --location -o $jfile -u $jfrog_user:$jfrog_passwd $jurl/$jfile"; do_system($cmd);