Running examples at dlang.org that use writeln or similar only display "1 unittests passed". This is probably caused by these examples being compiled with -unittest which adds a dubious unittest from std.format. When built with dmd 2.090 main isn't executed anymore if unittests are run, though.
Caused by https://github.com/dlang/druntime/pull/2877
Yes, we need to update dlang-tour to pass the right -DRT option when running the compiled executable.
If I compile with unittests enabled, I shouldn't get any unittests inserted from Phobos or druntime. IMO that's a bug in Phobos. On top of that, yes, the default for the online program runner should be to run both unittests and main, as that's the most useful thing you might want to do.
@rainers created dlang/phobos pull request #7359 "fix Issue 20500 - running examples on the home page only displays '1 …" fixing this issue: - fix Issue 20500 - running examples on the home page only displays '1 unittests passed' move unittests out of templated struct FormatSpec so they are not generated when using the template https://github.com/dlang/phobos/pull/7359
@wilzbach created dlang/dlang.org pull request #2739 "Fix Issue 20500 - always pass -unittest and --DRT-testmode=run-main" fixing this issue: - Fix Issue 20500 - always pass -unittest and --DRT-testmode=run-main https://github.com/dlang/dlang.org/pull/2739
dlang/phobos pull request #7359 "fix Issue 20500 - running examples on the home page only displays '1 …" was merged into stable: - 0105fc924f3c9be14269a833de0d8b57288816f0 by Rainer Schuetze: fix Issue 20500 - running examples on the home page only displays '1 unittests passed' move unittests out of templated struct FormatSpec so they are not generated when using the template https://github.com/dlang/phobos/pull/7359
dlang/dlang.org pull request #2739 "Fix Issue 20500 - always pass -unittest and --DRT-testmode=run-main" was merged into master: - 74a2d08bb4614df0483a7d64a104084b25e46b04 by Sebastian Wilzbach: Fix Issue 20500 - always pass -unittest and --DRT-testmode=run-main https://github.com/dlang/dlang.org/pull/2739