diff options
author | Ian Lance Taylor <iant@golang.org> | 2022-02-11 15:02:44 -0800 |
---|---|---|
committer | Ian Lance Taylor <iant@golang.org> | 2022-02-11 15:02:44 -0800 |
commit | 9a510fb0970d3d9a4201bce8965cabe67850386b (patch) | |
tree | 43d7fd2bbfd7ad8c9625a718a5e8718889351994 /libphobos/testsuite/libphobos.unittest/customhandler.d | |
parent | a6d3012b274f38b20e2a57162106f625746af6c6 (diff) | |
parent | 8dc2499aa62f768c6395c9754b8cabc1ce25c494 (diff) | |
download | gcc-9a510fb0970d3d9a4201bce8965cabe67850386b.zip gcc-9a510fb0970d3d9a4201bce8965cabe67850386b.tar.gz gcc-9a510fb0970d3d9a4201bce8965cabe67850386b.tar.bz2 |
Merge from trunk revision 8dc2499aa62f768c6395c9754b8cabc1ce25c494
Diffstat (limited to 'libphobos/testsuite/libphobos.unittest/customhandler.d')
-rw-r--r-- | libphobos/testsuite/libphobos.unittest/customhandler.d | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/libphobos/testsuite/libphobos.unittest/customhandler.d b/libphobos/testsuite/libphobos.unittest/customhandler.d new file mode 100644 index 0000000..f5a0435 --- /dev/null +++ b/libphobos/testsuite/libphobos.unittest/customhandler.d @@ -0,0 +1,21 @@ +import core.runtime; + +UnitTestResult customModuleUnitTester() +{ + version(GoodTests) return UnitTestResult(100, 100, false, true); + version(FailedTests) return UnitTestResult(100, 0, false, true); + version(NoTests) return UnitTestResult(0, 0, true, false); + version(FailNoPrintout) return UnitTestResult(100, 0, false, false); + version(PassNoPrintout) return UnitTestResult(100, 100, false, false); +} + +shared static this() +{ + Runtime.extendedModuleUnitTester = &customModuleUnitTester; +} + +void main() +{ + import core.stdc.stdio; + fprintf(stderr, "main\n"); +} |