[skip ci] fix tests

This commit is contained in:
az 2023-05-26 12:23:37 +02:00
parent 48232826b1
commit 1c0c038969

View file

@ -404,7 +404,6 @@ internal class ProvTest {
println(outContent.toString())
val expectedOutput =
"WARNING: method task should not be used at top-level, use method <session> instead.\n" +
"============================================== SUMMARY (test instance with no progress info) =============================================\n" +
"> \u001B[92mSuccess\u001B[0m -- taskA \n" +
"---> \u001B[92mSuccess\u001B[0m -- prov_marks_failed_output_yellow_if_optional (optional) \n" +
@ -475,7 +474,6 @@ internal class ProvTest {
println(outContent.toString())
val expectedOutput =
"WARNING: method task should not be used at top-level, use method <session> instead.\n" +
"============================================== SUMMARY (test instance) =============================================\n" +
"> \u001B[92mSuccess\u001B[0m -- TaskB \n" +
"---> \u001B[92mSuccess\u001B[0m -- taskC \n" +
@ -722,7 +720,6 @@ internal class ProvTest {
println(outContent.toString())
val expectedOutput =
"WARNING: method taskWithResult should not be used at top-level, use method <session> instead.\n" +
"============================================== SUMMARY (test instance with no progress info) =============================================\n" +
"> \u001B[91mFAILED\u001B[0m -- testMethodForOutputTest_with_returned_results \n" +
"---> \u001B[91mFAILED\u001B[0m -- sub1 \n" +
@ -791,9 +788,9 @@ internal class ProvTest {
System.setErr(PrintStream(errContent))
// when
Prov.newInstance(name = "test instance with no progress info", progressType = ProgressType.NONE)
Prov.newInstance(name = "test instance with no progress info", progressType = ProgressType.BASIC)
.tst_task().success
Prov.newInstance(name = "test instance with no progress info", progressType = ProgressType.NONE)
Prov.newInstance(name = "test instance with no progress info", progressType = ProgressType.BASIC)
.tst_task().success // test that also second run gets warning
// then
@ -804,6 +801,11 @@ internal class ProvTest {
val expectedOutputOneRun =
"WARNING: method task should not be used at top-level, use method <session> instead.\n" +
"---------- Processing started ----------\n" +
"> \u001B[90mexecuting...\u001B[0m -- tst_task\n" +
"---> \u001B[90mexecuting...\u001B[0m -- task_returningTrue\n" +
"---> \u001B[90mexecuting...\u001B[0m -- task_returningFalse\n" +
"---------- Processing completed ----------\n" +
"============================================== SUMMARY (test instance with no progress info) =============================================\n" +
"> \u001B[91mFAILED\u001B[0m -- tst_task \n" +
"---> \u001B[92mSuccess\u001B[0m -- task_returningTrue \n" +