Open martinmoene opened 7 years ago
Basically, you want parts of SelfTest to become self-contained and hosted on Wandbox or similar, correct?
Indeed, with the difference that SelfTest may be geared (too much) towards implementers, complete and overwhelming where mere users may need another approach to support their understanding.
Key:
See for example the examples linked from section Usage of lest.
Yeah, SelfTest's primary aim is to (mostly) guarantee that things didn't get broken by a change, secondary aim is a reference for someone who already knows Catch well and documentation for newbies is a very distant third.
Anyway, I can see some value in adding these, but honestly don't have much time (and what little I do, I'd like to use for different things), so this will likely either get put on a backburner, or someone else needs to put in a PR (hint, hint).
I can see some value in adding these
is what I liked to know ;)
Plan (in progress):
Overall, part 1:
examples
examples
doc/list-of-examples.md
)Overall, part 2 (in progress):
Examples, part 1:
Examples, part 2 (in progress):
Examples, rest:
I installed the Catch2 framework using the CMake installation and when I try to compile and run any example I get this error: CATCH_SINGLE_INCLUDE: command not found
this is how I compile an example:
$ g++ -std=c++11 -Wall -I$(CATCH_SINGLE_INCLUDE) -c 000-CatchMain.cpp
what is the purpose of the macro CATCH_SINGLE_INCLUDE
?
@ahadji05 It should contain path to the single-include version of catch.hpp
.
Readers of Catch' documentation may benefit from readily available, complete and executable examples that show a limited and coherent set of features and steps needed for compilation. The tutorial and reference documentation can then link to relevant examples that the reader can try, perhaps even online.
Compilation of these examples must be integrated with the continuous integration process. As such the examples become executable documentation geared towards the user.
For example:
Subjects that come to mind: