[pushed] testsuite: fix pytest detection unsupported message.

Message ID 1e05cf34-790c-9b55-e50a-05b8c07d67b6@suse.cz
State Committed
Headers
Series [pushed] testsuite: fix pytest detection unsupported message. |

Commit Message

Martin Liška Jan. 19, 2022, 6:40 a.m. UTC
  PR testsuite/104109

gcc/testsuite/ChangeLog:

	* lib/gcov.exp: Fix pytest detection unsupported message.
---
  gcc/testsuite/lib/gcov.exp | 5 ++---
  1 file changed, 2 insertions(+), 3 deletions(-)
  

Patch

diff --git a/gcc/testsuite/lib/gcov.exp b/gcc/testsuite/lib/gcov.exp
index 6c57515e229..9d5b2cdb86b 100644
--- a/gcc/testsuite/lib/gcov.exp
+++ b/gcc/testsuite/lib/gcov.exp
@@ -276,14 +276,13 @@  proc run-gcov-pytest { args } {
      set testcase [remote_download host $testcase]
      set result [remote_exec host $GCOV "$testcase -i"]
  
+    set pytest_script [lindex $args 1]
      if { ![check_effective_target_pytest3] } {
-      unsupported "$script pytest python3 is missing"
+      unsupported "$pytest_script pytest python3 is missing"
        return
      }
  
-    set pytest_script [lindex $args 1]
      setenv GCOV_PATH $testcase
-    verbose "pytest_script: $srcdir $subdir $pytest_script" 2
      spawn -noecho python3 -m pytest --color=no -rap -s --tb=no $srcdir/$subdir/$pytest_script
  
      set prefix "\[^\r\n\]*"