framework: fix deinitSession when using waiver xml
authorTapani Pälli <tapani.palli@intel.com>
Tue, 27 Oct 2020 10:27:37 +0000 (12:27 +0200)
committerAlexander Galazin <Alexander.Galazin@arm.com>
Fri, 6 Nov 2020 09:28:20 +0000 (04:28 -0500)
Take numWaived in to account when considering if run was ok, patch also
add result.numWaived to the total number of tests, otherwise we hit
following assert when running with waiver:

cts-runner: glcTestRunner.cpp:829: Unknown function:
Assertion `result.numExecuted == result.numPassed + result.numFailed +
           result.numNotSupported + result.numWarnings' failed.

Components: Framework, OpenGL

VK-GL-CTS issue: 2631

Affects:
   cts-runner

Change-Id: Iac776fd1174e5461c455282cecca208f0322358d
Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
external/openglcts/modules/runner/glcTestRunner.cpp

index c955d57..ce2e3ab 100644 (file)
@@ -823,10 +823,9 @@ void TestRunner::deinitSession(void)
        // Collect results.
        // \note NotSupported is treated as pass.
        const tcu::TestRunStatus& result = m_curSession->getResult();
-       bool                                      isOk =
-               result.numExecuted == (result.numPassed + result.numNotSupported + result.numWarnings) && result.isComplete;
+       bool isOk = result.numFailed == 0 && result.isComplete;
 
-       DE_ASSERT(result.numExecuted == result.numPassed + result.numFailed + result.numNotSupported + result.numWarnings);
+       DE_ASSERT(result.numExecuted == result.numPassed + result.numFailed + result.numNotSupported + result.numWarnings + result.numWaived);
 
        m_sessionsExecuted += 1;
        (isOk ? m_sessionsPassed : m_sessionsFailed) += 1;