[education/rkward] tests: Fix leakage of warnings

Thomas Friedrichsmeier null at kde.org
Thu May 1 12:28:54 BST 2025


Git commit 23bb4bca42a1d71baf261de4fcd90d00a6ac9631 by Thomas Friedrichsmeier.
Committed on 01/05/2025 at 11:26.
Pushed by tfry into branch 'master'.

Fix leakage of warnings

M  +2    -0    tests/rkward_application_tests.R

https://invent.kde.org/education/rkward/-/commit/23bb4bca42a1d71baf261de4fcd90d00a6ac9631

diff --git a/tests/rkward_application_tests.R b/tests/rkward_application_tests.R
index 113959c0d..b2663b500 100644
--- a/tests/rkward_application_tests.R
+++ b/tests/rkward_application_tests.R
@@ -299,6 +299,8 @@ suite <- new ("RKTestSuite", id="rkward_application_tests",
 			', submit.mode="submit")
 		}),
 		new ("RKTest", id="rk_output_test", call=function () {
+			optwarn <- options("warn"=1) # This test leaks warning messages, otherwise...
+			on.exit(options("warn"=optwarn))
 			sync_outfile <- function() {
 				# Manually notify frontend of current output file.  This is usually suppressed for auto-texting, but important, here, since
 				# the frontend uses this to detect, which output is active.



More information about the rkward-tracker mailing list