[education/rkward] /: Fix test verification condition

Thomas Friedrichsmeier null at kde.org
Sun Oct 2 12:45:04 BST 2022


Git commit a6329c41fea9e67bcbad4edf109c316549ee62aa by Thomas Friedrichsmeier.
Committed on 02/10/2022 at 11:44.
Pushed by tfry into branch 'master'.

Fix test verification condition

M  +1    -1    .kde-ci.yml
M  +2    -1    rkward/autotests/core_test.cpp

https://invent.kde.org/education/rkward/commit/a6329c41fea9e67bcbad4edf109c316549ee62aa

diff --git a/.kde-ci.yml b/.kde-ci.yml
index 9c9d31aa..0461eeb4 100644
--- a/.kde-ci.yml
+++ b/.kde-ci.yml
@@ -19,6 +19,6 @@ Dependencies:
     'frameworks/kcrash': '@stable'
 
 Options:
-  require-passing-tests-on: [ 'Linux', 'FreeBSD', 'Windows' ]
+  require-passing-tests-on: [ 'Linux', 'FreeBSD' ]
   tests-load-sensitve: True
   per-test-timeout: 120
diff --git a/rkward/autotests/core_test.cpp b/rkward/autotests/core_test.cpp
index 9d79b894..df1a4b79 100644
--- a/rkward/autotests/core_test.cpp
+++ b/rkward/autotests/core_test.cpp
@@ -225,7 +225,7 @@ private slots:
 			if (i % 4 == 0) {
 				RInterface::instance()->cancelAll();
 			} else if (i % 4 == 1) {
-				while (commands_out < i) {
+				while (commands_out <= i) {
 					qApp->processEvents();
 				}
 			} else if (i % 4 == 2) {
@@ -237,6 +237,7 @@ private slots:
 		// There needs to be some wiggle room, however, as this is inherently prone to race-conditions. (Commands finish running before getting cancelled, or they don't).
 		QVERIFY(cancelled_commands >= 25);
 		QVERIFY(cancelled_commands <= 75);
+		qDebug("%d out of %d commands were actually cancelled", cancelled_commands, commands_out);
 	}
 
 	void priorityCommandTest() {


More information about the rkward-tracker mailing list