Skip to content

Commit cdedb87

Browse files
rousonbonachea
authored andcommitted
fix(intentional failure): clarify output
1 parent 8cff32a commit cdedb87

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

test/modules/test_test_m.F90

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ function results() result(test_results)
3535
type(test_test_t) test_test
3636

3737
test_results = test_test%run([ &
38-
test_description_t("reporting failure if a single image fails a test", usher(check_one_image_fails)) &
38+
test_description_t("(this is an intentional failure intended for visual interpretation)", usher(check_one_image_fails)) &
3939
])
4040
end function
4141

@@ -47,7 +47,7 @@ function check_one_image_fails() result(test_diagnosis)
4747
#else
4848
associate(me => 1, images => 1)
4949
#endif
50-
test_diagnosis = .expect. (me == images)
50+
test_diagnosis = .expect. (me /= images)
5151
end associate
5252
end function
5353

test/unit_test_failure_test.F90

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ program unit_test_failure_test
1212
if (.not. command_line%argument_present([character(len=len("--help"))::"--help","-h"])) then
1313
associate(test_harness => test_harness_t([test_fixture_t(test_test_t())]))
1414
call test_harness%report_results
15+
print *, "If this message appears, the test did not fail as intended."
1516
end associate
1617
end if
1718
end associate

0 commit comments

Comments
 (0)