gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[gnurl] 227/282: ci/tests: Move CI test result creation above environmen


From: gnunet
Subject: [gnurl] 227/282: ci/tests: Move CI test result creation above environment setup
Date: Wed, 01 Apr 2020 14:31:32 +0200

This is an automated email from the git hooks/post-receive script.

ng0 pushed a commit to branch master
in repository gnurl.

commit 3feb60d289ed1987b8957a98e062699f4f004311
Author: Marc Hoersken <address@hidden>
AuthorDate: Tue Mar 3 12:49:53 2020 +0100

    ci/tests: Move CI test result creation above environment setup
    
    This avoids using our test servers as proxy to the AppVeyor API.
    
    Closes #5022
---
 tests/runtests.pl | 24 ++++++++++++++----------
 1 file changed, 14 insertions(+), 10 deletions(-)

diff --git a/tests/runtests.pl b/tests/runtests.pl
index 131aef926..51a84f09b 100755
--- a/tests/runtests.pl
+++ b/tests/runtests.pl
@@ -3358,6 +3358,19 @@ sub singletest {
         delete $oldenv{$var};
     }
 
+    # get the name of the test early
+    my @testname= getpart("client", "name");
+    my $testname = $testname[0];
+    $testname =~ s/\n//g;
+
+    # create test result in CI services
+    if(azure_check_environment() && $AZURE_RUN_ID) {
+        $AZURE_RESULT_ID = azure_create_test_result($AZURE_RUN_ID, $testnum, 
$testname);
+    }
+    elsif(appveyor_check_environment()) {
+        appveyor_create_test_result($testnum, $testname);
+    }
+
     # remove test server commands file before servers are started/verified
     unlink($FTPDCMD) if(-f $FTPDCMD);
 
@@ -3517,9 +3530,6 @@ sub singletest {
     my $CURLOUT="$LOGDIR/curl$testnum.out"; # curl output if not stdout
 
     # name of the test
-    my @testname= getpart("client", "name");
-    my $testname = $testname[0];
-    $testname =~ s/\n//g;
     logmsg "[$testname]\n" if(!$short);
 
     if($listonly) {
@@ -3743,13 +3753,6 @@ sub singletest {
         close(GDBCMD);
     }
 
-    if(azure_check_environment() && $AZURE_RUN_ID) {
-        $AZURE_RESULT_ID = azure_create_test_result($AZURE_RUN_ID, $testnum, 
$testname);
-    }
-    elsif(appveyor_check_environment()) {
-        appveyor_create_test_result($testnum, $testname);
-    }
-
     # timestamp starting of test command
     $timetoolini{$testnum} = Time::HiRes::time();
 
@@ -5543,6 +5546,7 @@ foreach $testnum (@at) {
 
     my $error = singletest($run_event_based, $testnum, $count, scalar(@at));
 
+    # update test result in CI services
     if(azure_check_environment() && $AZURE_RUN_ID && $AZURE_RESULT_ID) {
         $AZURE_RESULT_ID = azure_update_test_result($AZURE_RUN_ID, 
$AZURE_RESULT_ID, $testnum, $error,
                                                     $timeprepini{$testnum}, 
$timevrfyend{$testnum});

-- 
To stop receiving notification emails like this one, please contact
address@hidden.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]