diff --git a/.github/workflows/docs-deploy.yml b/.github/workflows/docs-deploy.yml new file mode 100644 index 0000000000..dedff1cb68 --- /dev/null +++ b/.github/workflows/docs-deploy.yml @@ -0,0 +1,26 @@ +name: Docs Build + +on: + push: + branches: + - devel + +jobs: + deploy: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-node@v3 + with: + node-version: 16 + cache: yarn + - run: yarn install --frozen-lockfile + + - name: Build + run: yarn docs:build + + - name: Deploy + uses: peaceiris/actions-gh-pages@v3 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: docs/.vitepress/dist diff --git a/.gitignore b/.gitignore index cafbd6b297..fedcb76efd 100644 --- a/.gitignore +++ b/.gitignore @@ -32,5 +32,12 @@ msvc-sln* # Currently we use Doxygen for dep graphs and the full docs are only slowly # being filled in, so we definitely do not want git to deal with the docs. docs/doxygen + +# vitepress +docs/.vitepress/dist/ +node_modules +yarn-error.log + + *.cache compile_commands.json diff --git a/docs-others/command-line.md b/docs-others/command-line.md new file mode 100644 index 0000000000..98f6770798 --- /dev/null +++ b/docs-others/command-line.md @@ -0,0 +1,582 @@ + +# Command line + +**Contents**
+[Specifying which tests to run](#specifying-which-tests-to-run)
+[Choosing a reporter to use](#choosing-a-reporter-to-use)
+[Breaking into the debugger](#breaking-into-the-debugger)
+[Showing results for successful tests](#showing-results-for-successful-tests)
+[Aborting after a certain number of failures](#aborting-after-a-certain-number-of-failures)
+[Listing available tests, tags or reporters](#listing-available-tests-tags-or-reporters)
+[Sending output to a file](#sending-output-to-a-file)
+[Naming a test run](#naming-a-test-run)
+[Eliding assertions expected to throw](#eliding-assertions-expected-to-throw)
+[Make whitespace visible](#make-whitespace-visible)
+[Warnings](#warnings)
+[Reporting timings](#reporting-timings)
+[Load test names to run from a file](#load-test-names-to-run-from-a-file)
+[Specify the order test cases are run](#specify-the-order-test-cases-are-run)
+[Specify a seed for the Random Number Generator](#specify-a-seed-for-the-random-number-generator)
+[Identify framework and version according to the libIdentify standard](#identify-framework-and-version-according-to-the-libidentify-standard)
+[Wait for key before continuing](#wait-for-key-before-continuing)
+[Skip all benchmarks](#skip-all-benchmarks)
+[Specify the number of benchmark samples to collect](#specify-the-number-of-benchmark-samples-to-collect)
+[Specify the number of resamples for bootstrapping](#specify-the-number-of-resamples-for-bootstrapping)
+[Specify the confidence-interval for bootstrapping](#specify-the-confidence-interval-for-bootstrapping)
+[Disable statistical analysis of collected benchmark samples](#disable-statistical-analysis-of-collected-benchmark-samples)
+[Specify the amount of time in milliseconds spent on warming up each test](#specify-the-amount-of-time-in-milliseconds-spent-on-warming-up-each-test)
+[Usage](#usage)
+[Specify the section to run](#specify-the-section-to-run)
+[Filenames as tags](#filenames-as-tags)
+[Override output colouring](#override-output-colouring)
+[Test Sharding](#test-sharding)
+[Allow running the binary without tests](#allow-running-the-binary-without-tests)
+[Output verbosity](#output-verbosity)
+ +Catch works quite nicely without any command line options at all - but for those times when you want greater control the following options are available. +Click one of the following links to take you straight to that option - or scroll on to browse the available options. + + ` ...`
+ ` -h, -?, --help`
+ ` -s, --success`
+ ` -b, --break`
+ ` -e, --nothrow`
+ ` -i, --invisibles`
+ ` -o, --out`
+ ` -r, --reporter`
+ ` -n, --name`
+ ` -a, --abort`
+ ` -x, --abortx`
+ ` -w, --warn`
+ ` -d, --durations`
+ ` -f, --input-file`
+ ` -c, --section`
+ ` -#, --filenames-as-tags`
+ + +
+ + ` --list-tests`
+ ` --list-tags`
+ ` --list-reporters`
+ ` --list-listeners`
+ ` --order`
+ ` --rng-seed`
+ ` --libidentify`
+ ` --wait-for-keypress`
+ ` --skip-benchmarks`
+ ` --benchmark-samples`
+ ` --benchmark-resamples`
+ ` --benchmark-confidence-interval`
+ ` --benchmark-no-analysis`
+ ` --benchmark-warmup-time`
+ ` --colour-mode`
+ ` --shard-count`
+ ` --shard-index`
+ ` --allow-running-no-tests`
+ ` --verbosity`
+ +
+ + + + +## Specifying which tests to run + +
<test-spec> ...
+ +Test cases, wildcarded test cases, tags and tag expressions are all passed directly as arguments. Tags are distinguished by being enclosed in square brackets. + +If no test specs are supplied then all test cases, except "hidden" tests, are run. +A test is hidden by giving it any tag starting with (or just) a period (```.```) - or, in the deprecated case, tagged ```[hide]``` or given name starting with `'./'`. To specify hidden tests from the command line ```[.]``` or ```[hide]``` can be used *regardless of how they were declared*. + +Specs must be enclosed in quotes if they contain spaces. If they do not contain spaces the quotes are optional. + +Wildcards consist of the `*` character at the beginning and/or end of test case names and can substitute for any number of any characters (including none). + +Test specs are case insensitive. + +If a spec is prefixed with `exclude:` or the `~` character then the pattern matches an exclusion. This means that tests matching the pattern are excluded from the set - even if a prior inclusion spec included them. Subsequent inclusion specs will take precedence, however. +Inclusions and exclusions are evaluated in left-to-right order. + +Test case examples: + +``` +thisTestOnly Matches the test case called, 'thisTestOnly' +"this test only" Matches the test case called, 'this test only' +these* Matches all cases starting with 'these' +exclude:notThis Matches all tests except, 'notThis' +~notThis Matches all tests except, 'notThis' +~*private* Matches all tests except those that contain 'private' +a* ~ab* abc Matches all tests that start with 'a', except those that + start with 'ab', except 'abc', which is included +~[tag1] Matches all tests except those tagged with '[tag1]' +-# [#somefile] Matches all tests from the file 'somefile.cpp' +``` + +Names within square brackets are interpreted as tags. +A series of tags form an AND expression whereas a comma-separated sequence forms an OR expression. e.g.: + +
[one][two],[three]
+This matches all tests tagged `[one]` and `[two]`, as well as all tests tagged `[three]` + +Test names containing special characters, such as `,` or `[` can specify them on the command line using `\`. +`\` also escapes itself. + + +## Choosing a reporter to use + +
-r, --reporter <reporter[::key=value]*>
+ +Reporters are how the output from Catch2 (results of assertions, tests, +benchmarks and so on) is formatted and written out. The default reporter +is called the "Console" reporter and is intended to provide relatively +verbose and human-friendly output. + +Reporters are also individually configurable. To pass configuration options +to the reporter, you append `::key=value` to the reporter specification +as many times as you want, e.g. `--reporter xml::out=someFile.xml`. + +The keys must either be prefixed by "X", in which case they are not parsed +by Catch2 and are only passed down to the reporter, or one of options +hardcoded into Catch2. Currently there are only 2, +["out"](#sending-output-to-a-file), and ["colour-mode"](#colour-mode). + +_Note that the reporter might still check the X-prefixed options for +validity, and throw an error if they are wrong._ + +> Support for passing arguments to reporters through the `-r`, `--reporter` flag was introduced in Catch2 3.0.1 + +There are multiple built-in reporters, you can see what they do by using the +[`--list-reporter`](command-line.md#listing-available-tests-tags-or-reporters) +flag. If you need a reporter providing custom format outside of the already +provided ones, look at the ["write your own reporter" part of the reporter +documentation](reporters.md#writing-your-own-reporter). + +This option may be passed multiple times to use multiple (different) +reporters at the same time. See the [reporter documentation](reporters.md#multiple-reporters) +for details on what the resulting behaviour is. Also note that at most one +reporter can be provided without the output-file part of reporter spec. +This reporter will use the "default" output destination, based on +the [`-o`, `--out`](#sending-output-to-a-file) option. + +> Support for using multiple different reporters at the same time was [introduced](https://github.com/catchorg/Catch2/pull/2183) in Catch2 3.0.1 + + +_Note: There is currently no way to escape `::` in the reporter spec, +and thus the reporter names, or configuration keys and values, cannot +contain `::`. As `::` in paths is relatively obscure (unlike ':'), we do +not consider this an issue._ + + + +## Breaking into the debugger +
-b, --break
+ +Under most debuggers Catch2 is capable of automatically breaking on a test +failure. This allows the user to see the current state of the test during +failure. + + +## Showing results for successful tests +
-s, --success
+ +Usually you only want to see reporting for failed tests. Sometimes it's useful to see *all* the output (especially when you don't trust that that test you just added worked first time!). +To see successful, as well as failing, test results just pass this option. Note that each reporter may treat this option differently. The Junit reporter, for example, logs all results regardless. + + +## Aborting after a certain number of failures +
-a, --abort
+-x, --abortx [<failure threshold>]
+
+ +If a ```REQUIRE``` assertion fails the test case aborts, but subsequent test cases are still run. +If a ```CHECK``` assertion fails even the current test case is not aborted. + +Sometimes this results in a flood of failure messages and you'd rather just see the first few. Specifying ```-a``` or ```--abort``` on its own will abort the whole test run on the first failed assertion of any kind. Use ```-x``` or ```--abortx``` followed by a number to abort after that number of assertion failures. + + +## Listing available tests, tags or reporters +``` +--list-tests +--list-tags +--list-reporters +--list-listeners +``` + +> The `--list*` options became customizable through reporters in Catch2 3.0.1 + +> The `--list-listeners` option was added in Catch2 3.0.1 + +`--list-tests` lists all registered tests matching specified test spec. +Usually this listing also includes tags, and potentially also other +information, like source location, based on verbosity and reporter's design. + +`--list-tags` lists all tags from registered tests matching specified test +spec. Usually this also includes number of tests cases they match and +similar information. + +`--list-reporters` lists all available reporters and their descriptions. + +`--list-listeners` lists all registered listeners and their descriptions. + +The [`--verbosity` argument](#output-verbosity) modifies the level of detail provided by the default `--list*` options +as follows: + +| Option | `normal` (default) | `quiet` | `high` | +|--------------------|---------------------------------|---------------------|-----------------------------------------| +| `--list-tests` | Test names and tags | Test names only | Same as `normal`, plus source code line | +| `--list-tags` | Tags and counts | Same as `normal` | Same as `normal` | +| `--list-reporters` | Reporter names and descriptions | Reporter names only | Same as `normal` | +| `--list-listeners` | Listener names and descriptions | Same as `normal` | Same as `normal` | + + +## Sending output to a file +
-o, --out <filename>
+
+ +Use this option to send all output to a file, instead of stdout. You can +use `-` as the filename to explicitly send the output to stdout (this is +useful e.g. when using multiple reporters). + +> Support for `-` as the filename was introduced in Catch2 3.0.1 + +Filenames starting with "%" (percent symbol) are reserved by Catch2 for +meta purposes, e.g. using `%debug` as the filename opens stream that +writes to platform specific debugging/logging mechanism. + +Catch2 currently recognizes 3 meta streams: + +* `%debug` - writes to platform specific debugging/logging output +* `%stdout` - writes to stdout +* `%stderr` - writes to stderr + +> Support for `%stdout` and `%stderr` was introduced in Catch2 3.0.1 + + + +## Naming a test run +
-n, --name <name for test run>
+ +If a name is supplied it will be used by the reporter to provide an overall name for the test run. This can be useful if you are sending to a file, for example, and need to distinguish different test runs - either from different Catch executables or runs of the same executable with different options. If not supplied the name is defaulted to the name of the executable. + + +## Eliding assertions expected to throw +
-e, --nothrow
+ +Skips all assertions that test that an exception is thrown, e.g. ```REQUIRE_THROWS```. + +These can be a nuisance in certain debugging environments that may break when exceptions are thrown (while this is usually optional for handled exceptions, it can be useful to have enabled if you are trying to track down something unexpected). + +Sometimes exceptions are expected outside of one of the assertions that tests for them (perhaps thrown and caught within the code-under-test). The whole test case can be skipped when using ```-e``` by marking it with the ```[!throws]``` tag. + +When running with this option any throw checking assertions are skipped so as not to contribute additional noise. Be careful if this affects the behaviour of subsequent tests. + + +## Make whitespace visible +
-i, --invisibles
+ +If a string comparison fails due to differences in whitespace - especially leading or trailing whitespace - it can be hard to see what's going on. +This option transforms tabs and newline characters into ```\t``` and ```\n``` respectively when printing. + + +## Warnings +
-w, --warn <warning name>
+ +You can think of Catch2's warnings as the equivalent of `-Werror` (`/WX`) +flag for C++ compilers. It turns some suspicious occurences, like a section +without assertions, into errors. Because these might be intended, warnings +are not enabled by default, but user can opt in. + +You can enable multiple warnings at the same time. + +There are currently two warnings implemented: + +``` + NoAssertions // Fail test case / leaf section if no assertions + // (e.g. `REQUIRE`) is encountered. + UnmatchedTestSpec // Fail test run if any of the CLI test specs did + // not match any tests. +``` + +> `UnmatchedTestSpec` was introduced in Catch2 3.0.1. + + + +## Reporting timings +
-d, --durations <yes/no>
+ +When set to ```yes``` Catch will report the duration of each test case, in milliseconds. Note that it does this regardless of whether a test case passes or fails. Note, also, the certain reporters (e.g. Junit) always report test case durations regardless of this option being set or not. + +
-D, --min-duration <value>
+ +> `--min-duration` was [introduced](https://github.com/catchorg/Catch2/pull/1910) in Catch2 2.13.0 + +When set, Catch will report the duration of each test case that took more +than <value> seconds, in milliseconds. This option is overriden by both +`-d yes` and `-d no`, so that either all durations are reported, or none +are. + + + +## Load test names to run from a file +
-f, --input-file <filename>
+ +Provide the name of a file that contains a list of test case names, +one per line. Blank lines are skipped. + +A useful way to generate an initial instance of this file is to combine +the [`--list-tests`](#listing-available-tests-tags-or-reporters) flag with +the [`--verbosity quiet`](#output-verbosity) option. You can also +use test specs to filter this list down to what you want first. + + + +## Specify the order test cases are run +
--order <decl|lex|rand>
+ +Test cases are ordered one of three ways: + +### decl +Declaration order (this is the default order if no --order argument is provided). +Tests in the same TU are sorted using their declaration orders, different +TUs are in an implementation (linking) dependent order. + + +### lex +Lexicographic order. Tests are sorted by their name, their tags are ignored. + + +### rand + +Randomly ordered. The order is dependent on Catch2's random seed (see +[`--rng-seed`](#rng-seed)), and is subset invariant. What this means +is that as long as the random seed is fixed, running only some tests +(e.g. via tag) does not change their relative order. + +> The subset stability was introduced in Catch2 v2.12.0 + +Since the random order was made subset stable, we promise that given +the same random seed, the order of test cases will be the same across +different platforms, as long as the tests were compiled against identical +version of Catch2. We reserve the right to change the relative order +of tests cases between Catch2 versions, but it is unlikely to happen often. + + + +## Specify a seed for the Random Number Generator +
--rng-seed <'time'|'random-device'|number>
+ +Sets the seed for random number generators used by Catch2. These are used +e.g. to shuffle tests when user asks for tests to be in random order. + +Using `time` as the argument asks Catch2 generate the seed through call +to `std::time(nullptr)`. This provides very weak randomness and multiple +runs of the binary can generate the same seed if they are started close +to each other. + +Using `random-device` asks for `std::random_device` to be used instead. +If your implementation provides working `std::random_device`, it should +be preferred to using `time`. Catch2 uses `std::random_device` by default. + + + +## Identify framework and version according to the libIdentify standard +
--libidentify
+ +See [The LibIdentify repo for more information and examples](https://github.com/janwilmans/LibIdentify). + + +## Wait for key before continuing +
--wait-for-keypress <never|start|exit|both>
+ +Will cause the executable to print a message and wait until the return/ enter key is pressed before continuing - +either before running any tests, after running all tests - or both, depending on the argument. + + +## Skip all benchmarks +
--skip-benchmarks
+ +> [Introduced](https://github.com/catchorg/Catch2/issues/2408) in Catch2 3.0.1. + +This flag tells Catch2 to skip running all benchmarks. Benchmarks in this +case mean code blocks in `BENCHMARK` and `BENCHMARK_ADVANCED` macros, not +test cases with the `[!benchmark]` tag. + + +## Specify the number of benchmark samples to collect +
--benchmark-samples <# of samples>
+ +> [Introduced](https://github.com/catchorg/Catch2/issues/1616) in Catch2 2.9.0. + +When running benchmarks a number of "samples" is collected. This is the base data for later statistical analysis. +Per sample a clock resolution dependent number of iterations of the user code is run, which is independent of the number of samples. Defaults to 100. + + +## Specify the number of resamples for bootstrapping +
--benchmark-resamples <# of resamples>
+ +> [Introduced](https://github.com/catchorg/Catch2/issues/1616) in Catch2 2.9.0. + +After the measurements are performed, statistical [bootstrapping] is performed +on the samples. The number of resamples for that bootstrapping is configurable +but defaults to 100000. Due to the bootstrapping it is possible to give +estimates for the mean and standard deviation. The estimates come with a lower +bound and an upper bound, and the confidence interval (which is configurable but +defaults to 95%). + + [bootstrapping]: http://en.wikipedia.org/wiki/Bootstrapping_%28statistics%29 + + +## Specify the confidence-interval for bootstrapping +
--benchmark-confidence-interval <confidence-interval>
+ +> [Introduced](https://github.com/catchorg/Catch2/issues/1616) in Catch2 2.9.0. + +The confidence-interval is used for statistical bootstrapping on the samples to +calculate the upper and lower bounds of mean and standard deviation. +Must be between 0 and 1 and defaults to 0.95. + + +## Disable statistical analysis of collected benchmark samples +
--benchmark-no-analysis
+ +> [Introduced](https://github.com/catchorg/Catch2/issues/1616) in Catch2 2.9.0. + +When this flag is specified no bootstrapping or any other statistical analysis is performed. +Instead the user code is only measured and the plain mean from the samples is reported. + + +## Specify the amount of time in milliseconds spent on warming up each test +
--benchmark-warmup-time
+ +> [Introduced](https://github.com/catchorg/Catch2/pull/1844) in Catch2 2.11.2. + +Configure the amount of time spent warming up each test. + + +## Usage +
-h, -?, --help
+ +Prints the command line arguments to stdout + + + +## Specify the section to run +
-c, --section <section name>
+ +To limit execution to a specific section within a test case, use this option one or more times. +To narrow to sub-sections use multiple instances, where each subsequent instance specifies a deeper nesting level. + +E.g. if you have: + +
+TEST_CASE( "Test" ) {
+  SECTION( "sa" ) {
+    SECTION( "sb" ) {
+      /*...*/
+    }
+    SECTION( "sc" ) {
+      /*...*/
+    }
+  }
+  SECTION( "sd" ) {
+    /*...*/
+  }
+}
+
+ +Then you can run `sb` with: +
./MyExe Test -c sa -c sb
+ +Or run just `sd` with: +
./MyExe Test -c sd
+ +To run all of `sa`, including `sb` and `sc` use: +
./MyExe Test -c sa
+ +There are some limitations of this feature to be aware of: +- Code outside of sections being skipped will still be executed - e.g. any set-up code in the TEST_CASE before the +start of the first section.
+- At time of writing, wildcards are not supported in section names. +- If you specify a section without narrowing to a test case first then all test cases will be executed +(but only matching sections within them). + + + +## Filenames as tags +
-#, --filenames-as-tags
+ +When this option is used then every test is given an additional tag which is formed of the unqualified +filename it is found in, with any extension stripped, prefixed with the `#` character. + +So, for example, tests within the file `~\Dev\MyProject\Ferrets.cpp` would be tagged `[#Ferrets]`. + + +## Override output colouring +
--colour-mode <ansi|win32|none|default>
+ +> The `--colour-mode` option replaced the old `--colour` option in Catch2 3.0.1 + + +Catch2 support two different ways of colouring terminal output, and by +default it attempts to make a good guess on which implementation to use +(and whether to even use it, e.g. Catch2 tries to avoid writing colour +codes when writing the results into a file). + +`--colour-mode` allows the user to explicitly select what happens. + +* `--colour-mode ansi` tells Catch2 to always use ANSI colour codes, even +when writing to a file +* `--colour-mode win32` tells Catch2 to use colour implementation based + on Win32 terminal API +* `--colour-mode none` tells Catch2 to disable colours completely +* `--colour-mode default` lets Catch2 decide + +`--colour-mode default` is the default setting. + + + +## Test Sharding +
--shard-count <#number of shards>, --shard-index <#shard index to run>
+ +> [Introduced](https://github.com/catchorg/Catch2/pull/2257) in Catch2 3.0.1. + +When `--shard-count <#number of shards>` is used, the tests to execute +will be split evenly in to the given number of sets, identified by indices +starting at 0. The tests in the set given by +`--shard-index <#shard index to run>` will be executed. The default shard +count is `1`, and the default index to run is `0`. + +_It is an error to specify a shard index greater than the number of shards._ + +Sharding is useful when you want to split test execution across multiple +processes, as is done with the [Bazel test sharding](https://docs.bazel.build/versions/main/test-encyclopedia.html#test-sharding). + + + +## Allow running the binary without tests +
--allow-running-no-tests
+ +> Introduced in Catch2 3.0.1. + +By default, Catch2 test binaries return non-0 exit code if no tests were +run, e.g. if the binary was compiled with no tests, or the provided test +spec matched no tests. This flag overrides that, so a test run with no +tests still returns 0. + +## Output verbosity +``` +-v, --verbosity +``` + +Changing verbosity might change how much details Catch2's reporters output. +However, you should consider changing the verbosity level as a _suggestion_. +Not all reporters support all verbosity levels, e.g. because the reporter's +format cannot meaningfully change. In that case, the verbosity level is +ignored. + +Verbosity defaults to _normal_. + +*** + diff --git a/docs-others/release-notes.md b/docs-others/release-notes.md new file mode 100644 index 0000000000..037a1e34c3 --- /dev/null +++ b/docs-others/release-notes.md @@ -0,0 +1,1517 @@ + + +# Release notes +**Contents**
+[3.1.0](#310)
+[3.0.1](#301)
+[2.13.7](#2137)
+[2.13.6](#2136)
+[2.13.5](#2135)
+[2.13.4](#2134)
+[2.13.3](#2133)
+[2.13.2](#2132)
+[2.13.1](#2131)
+[2.13.0](#2130)
+[2.12.4](#2124)
+[2.12.3](#2123)
+[2.12.2](#2122)
+[2.12.1](#2121)
+[2.12.0](#2120)
+[2.11.3](#2113)
+[2.11.2](#2112)
+[2.11.1](#2111)
+[2.11.0](#2110)
+[2.10.2](#2102)
+[2.10.1](#2101)
+[2.10.0](#2100)
+[2.9.2](#292)
+[2.9.1](#291)
+[2.9.0](#290)
+[2.8.0](#280)
+[2.7.2](#272)
+[2.7.1](#271)
+[2.7.0](#270)
+[2.6.1](#261)
+[2.6.0](#260)
+[2.5.0](#250)
+[2.4.2](#242)
+[2.4.1](#241)
+[2.4.0](#240)
+[2.3.0](#230)
+[2.2.3](#223)
+[2.2.2](#222)
+[2.2.1](#221)
+[2.2.0](#220)
+[2.1.2](#212)
+[2.1.1](#211)
+[2.1.0](#210)
+[2.0.1](#201)
+[Older versions](#older-versions)
+[Even Older versions](#even-older-versions)
+ + +## 3.1.0 + +### Improvements +* Improved suppression of `-Wparentheses` for older GCCs + * Turns out that even GCC 9 does not properly handle `_Pragma`s in the C++ frontend. +* Added type constraints onto `random` generator (#2433) + * These constraints copy what the standard says for the underlying `std::uniform_int_distribution` +* Suppressed -Wunused-variable from nvcc (#2306, #2427) +* Suppressed -Wunused-variable from MinGW (#2132) +* Added All/Any/NoneTrue range matchers (#2319) + * These check that all/any/none of boolean values in a range are true. +* The JUnit reporter now normalizes classnames from C++ namespaces to Java-like namespaces (#2468) + * This provides better support for other JUnit based tools. +* The Bazel support now understands `BAZEL_TEST` environment variable (#2459) + * The `CATCH_CONFIG_BAZEL_SUPPORT` configuration option is also still supported. +* Returned support for compiling Catch2 with GCC 5 (#2448) + * This required removing inherited constructors from Catch2's internals. + * I recommend updating to a newer GCC anyway. +* `catch_discover_tests` now has a new options for setting library load path(s) when running the Catch2 binary (#2467) + + +### Fixes +* Fixed crash when listing listeners without any registered listeners (#2442) +* Fixed nvcc compilation error in constructor benchmarking helper (#2477) +* Catch2's CMakeList supports pre-3.12 CMake again (#2428) + * The gain from requiring CMake 3.12 was very minor, but y'all should really update to newer CMake + + +### Miscellaneous +* Fixed SelfTest build on MinGW (#2447) +* The in-repo conan recipe exports the CMake helper (#2460) +* Added experimental CMake script to showcase using test case sharding together with CTest + * Compared to `catch_discover_tests`, it supports very limited number of options and customization +* Added documentation page on best practices when running Catch2 tests +* Catch2 can be built as a dynamic library (#2397, #2398) + * Note that Catch2 does not have visibility annotations, and you are responsible for ensuring correct visibility built into the resulting library. + + + +## 3.0.1 + +**Catch2 now uses statically compiled library as its distribution model. +This also means that to get all of Catch2's functionality in a test file, +you have to include multiple headers.** + +You probably want to look into the [migration docs](migrate-v2-to-v3.md#top), +which were written to help people coming from v2.x.x versions to the +v3 releases. + + +### FAQ + +* Why is Catch2 moving to separate headers? + * The short answer is future extensibility and scalability. The long answer is complex and can be found on my blog, but at the most basic level, it is that providing single-header distribution is at odds with providing variety of useful features. When Catch2 was distributed in a single header, adding a new Matcher would cause overhead for everyone, but was useful only to a subset of users. This meant that the barrier to entry for new Matchers/Generators/etc is high in single header model, but much smaller in the new model. +* Will Catch2 again distribute single-header version in the future? + * No. But we do provide sqlite-style amalgamated distribution option. This means that you can download just 1 .cpp file and 1 header and place them next to your own sources. However, doing this has downsides similar to using the `catch_all.hpp` header. +* Why the big breaking change caused by replacing `catch.hpp` with `catch_all.hpp`? + * The convenience header `catch_all.hpp` exists for two reasons. One of them is to provide a way for quick migration from Catch2, the second one is to provide a simple way to test things with Catch2. Using it for migration has one drawback in that it is **big**. This means that including it _will_ cause significant compile time drag, and so using it to migrate should be a conscious decision by the user, not something they can just stumble into unknowingly. + + +### (Potentially) Breaking changes +* **Catch2 now uses statically compiled library as its distribution model** + * **Including `catch.hpp` no longer works** +* **Catch2 now uses C++14 as the minimum support language version** +* `ANON_TEST_CASE` has been removed, use `TEST_CASE` with no arguments instead (#1220) +* `--list*` commands no longer have non-zero return code (#1410) +* `--list-test-names-only` has been removed (#1190) + * You should use verbosity-modifiers for `--list-tests` instead +* `--list*` commands are now piped through the reporters + * The top-level reporter interface provides default implementation that works just as the old one + * XmlReporter outputs a machine-parseable XML +* `TEST_CASE` description support has been removed + * If the second argument has text outside tags, the text will be ignored. +* Hidden test cases are no longer included just because they don't match an exclusion tag + * Previously, a `TEST_CASE("A", "[.foo]")` would be included by asking for `~[bar]`. +* `PredicateMatcher` is no longer type erased. + * This means that the type of the provided predicate is part of the `PredicateMatcher`'s type +* `SectionInfo` no longer contains section description as a member (#1319) + * You can still write `SECTION("ShortName", "Long and wordy description")`, but the description is thrown away + * The description type now must be a `const char*` or be implicitly convertible to it +* The `[!hide]` tag has been removed. + * Use `[.]` or `[.foo]` instead. +* Lvalues of composed matchers cannot be composed further +* Uses of `REGISTER_TEST_CASE` macro need to be followed by a semicolon + * This does not change `TEST_CASE` and friends in any way +* `IStreamingReporter::IsMulti` member function was removed + * This is _very_ unlikely to actually affect anyone, as it was default-implemented in the interface, and only used internally +* Various classes not designed for user-extension have been made final + * `ListeningReporter` is now `final` + * Concrete Matchers (e.g. `UnorderedEquals` vector matcher) are now `final` + * All Generators are now `final` +* Matcher namespacing has been redone + * Matcher types are no longer in deeply nested namespaces + * Matcher factory functions are no longer brought into `Catch` namespace + * This means that all public-facing matcher-related functionality is now in `Catch::Matchers` namespace +* Defining `CATCH_CONFIG_MAIN` will no longer create main in that TU. + * Link with `libCatch2Main.a`, or the proper CMake/pkg-config target + * If you want to write custom main, include `catch2/catch_session.hpp` +* `CATCH_CONFIG_EXTERNAL_INTERFACES` has been removed. + * You should instead include the appropriate headers as needed. +* `CATCH_CONFIG_IMPL` has been removed. + * The implementation is now compiled into a static library. +* Event Listener interface has changed + * `TestEventListenerBase` was renamed to `EventListenerBase` + * `EventListenerBase` now directly derives from `IStreamingReporter`, instead of deriving from `StreamingReporterBase` +* `GENERATE` decays its arguments (#2012, #2040) + * This means that `str` in `auto str = GENERATE("aa", "bb", "cc");` is inferred to `char const*` rather than `const char[2]`. +* `--list-*` flags write their output to file specified by the `-o` flag +* Many changes to reporter interfaces + * With the exception of the XmlReporter, the outputs of first party reporters should remain the same + * New pair of events were added + * One obsolete event was removed + * The base class has been renamed + * The built-in reporter class hierarchy has been redone +* Catch2 generates a random seed if one hasn't been specified by the user +* The short flag for `--list-tests`, `-l`, has been removed. + * This is not a commonly used flag and does not need to use up valuable single-letter space. +* The short flag for `--list-tags`, `-t`, has been removed. + * This is not a commonly used flag and does not need to use up valuable single-letter space. +* The `--colour` option has been replaced with `--colour-mode` option + + +### Improvements +* Matchers have been extended with the ability to use different signatures of `match` (#1307, #1553, #1554, #1843) + * This includes having templated `match` member function + * See the [rewritten Matchers documentation](matchers.md#top) for details + * Catch2 currently provides _some_ generic matchers, but there should be more before final release of v3 + * `IsEmpty`, `SizeIs` which check that the range has specific properties + * `Contains`, which checks whether a range contains a specific element + * `AllMatch`, `AnyMatch`, `NoneMatch` range matchers, which apply matchers over a range of elements +* Significant compilation time improvements + * including `catch_test_macros.hpp` is 80% cheaper than including `catch.hpp` +* Some runtime performance optimizations + * In all tested cases the v3 branch was faster, so the table below shows the speedup of v3 to v2 at the same task + + +| task | debug build | release build | +|:------------------------------------------- | ------------:| -------------:| +| Run 1M `REQUIRE(true)` | 1.10 ± 0.01 | 1.02 ± 0.06 | +| Run 100 tests, 3^3 sections, 1 REQUIRE each | 1.27 ± 0.01 | 1.04 ± 0.01 | +| Run 3k tests, no names, no tags | 1.29 ± 0.01 | 1.05 ± 0.01 | +| Run 3k tests, names, tags | 1.49 ± 0.01 | 1.22 ± 0.01 | +| Run 1 out of 3k tests no names, no tags | 1.68 ± 0.02 | 1.19 ± 0.22 | +| Run 1 out of 3k tests, names, tags | 1.79 ± 0.02 | 2.06 ± 0.23 | + + +* POSIX platforms use `gmtime_r`, rather than `gmtime` when constructing a date string (#2008, #2165) +* `--list-*` flags write their output to file specified by the `-o` flag (#2061, #2163) +* `Approx::operator()` is now properly `const` +* Catch2's internal helper variables no longer use reserved identifiers (#578) +* `--rng-seed` now accepts string `"random-device"` to generate random seed using `std::random_device` +* Catch2 now supports test sharding (#2257) + * You can ask for the tests to be split into N groups and only run one of them. + * This greatly simplifies parallelization of tests in a binary through external runner. +* The embedded CLI parser now supports repeatedly callable lambdas + * A lambda-based option parser can opt into being repeatedly specifiable. +* Added `STATIC_CHECK` macro, similar to `STATIC_REQUIRE` (#2318) + * When deferred tu runtime, it behaves like `CHECK`, and not like `REQUIRE`. +* You can have multiple tests with the same name, as long as other parts of the test identity differ (#1915, #1999, #2175) + * Test identity includes test's name, test's tags and and test's class name if applicable. +* Added new warning, `UnmatchedTestSpec`, to error on test specs with no matching tests +* The `-w`, `--warn` warning flags can now be provided multiple times to enable multiple warnings +* The case-insensitive handling of tags is now more reliable and takes up less memory +* Test case and assertion counting can no longer reasonably overflow on 32 bit systems + * The count is now kept in `uint64_t` on all platforms, instead of using `size_t` type. +* The `-o`, `--out` output destination specifiers recognize `-` as stdout + * You have to provide it as `--out=-` to avoid CLI error about missing option + * The new reporter specification also recognizes `-` as stdout +* Multiple reporters can now run at the same time and write to different files (#1712, #2183) + * To support this, the `-r`, `--reporter` flag now also accepts optional output destination + * For full overview of the semantics of using multiple reporters, look into the reporter documentation + * To enable the new syntax, reporter names can no longer contain `::`. +* Console colour support has been rewritten and significantly improved + * The colour implementation based on ANSI colour codes is always available + * Colour implementations respect their associated stream + * previously e.g. Win32 impl would change console colour even if Catch2 was writing to a file + * The colour API is resilient against changing evaluation order of expressions + * The associated CLI flag and compile-time configuration options have changed + * For details see the docs for command-line and compile-time Catch2 configuration +* Added a support for Bazel integration with `XML_OUTPUT_FILE` env var (#2399) + * This has to be enabled during compilation. +* Added `--skip-benchmarks` flag to run tests without any `BENCHMARK`s (#2392, #2408) +* Added option to list all listeners in the binary via `--list-listeners` + + +### Fixes +* The `INFO` macro no longer contains superfluous semicolon (#1456) +* The `--list*` family of command line flags now return 0 on success (#1410, #1146) +* Various ways of failing a benchmark are now counted and reporter properly +* The ULP matcher now handles comparing numbers with different signs properly (#2152) +* Universal ADL-found operators should no longer break decomposition (#2121) +* Reporter selection is properly case-insensitive + * Previously it forced lower cased name, which would fail for reporters with upper case characters in name +* The cumulative reporter base stores benchmark results alongside assertion results +* Catch2's SE handling should no longer interferes with ASan on Windows (#2334) +* Fixed Windows console colour handling for tests that redirect stdout (#2345) +* Fixed issue with the `random` generators returning the same value over and over again + + +### Other changes +* `CATCH_CONFIG_DISABLE_MATCHERS` no longer exists. + * If you do not want to use Matchers in a TU, do not include their header. +* `CATCH_CONFIG_ENABLE_CHRONO_STRINGMAKER` no longer exists. + * `StringMaker` specializations for `` are always provided +* Catch2's CMake now provides 2 targets, `Catch2` and `Catch2WithMain`. + * `Catch2` is the statically compiled implementation by itself + * `Catch2WithMain` also links in the default main +* Catch2's pkg-config integration also provides 2 packages + * `catch2` is the statically compiled implementation by itself + * `catch2-with-main` also links in the default main +* Passing invalid test specifications passed to Catch2 are now reported before tests are run, and are a hard error. +* Running 0 tests (e.g. due to empty binary, or test spec not matching anything) returns non-0 exit code + * Flag `--allow-running-no-tests` overrides this behaviour. + * `NoTests` warning has been removed because it is fully subsumed by this change. +* Catch2's compile-time configuration options (`CATCH_CONFIG_FOO`) can be set through CMake options of the same name + * They use the same semantics as C++ defines, including the `CATCH_CONFIG_NO_FOO` overrides, + * `-DCATCH_CONFIG_DEFAULT_REPORTER=compact` changes default reporter to "compact" + * `-DCATCH_CONFIG_NO_ANDROID_LOGWRITE=ON` forces android logwrite to off + * `-DCATCH_CONFIG_ANDROID_LOGWRITE=OFF` does nothing (the define will not exist) + + + +## 2.13.7 + +### Fixes +* Added missing `` include in benchmarking. (#2231) +* Fixed noexcept build with benchmarking enabled (#2235) +* Fixed build for compilers with C++17 support but without C++17 library support (#2195) +* JUnit only uses 3 decimal places when reporting durations (#2221) +* `!mayfail` tagged tests are now marked as `skipped` in JUnit reporter output (#2116) + + +## 2.13.6 + +### Fixes +* Disabling all signal handlers no longer breaks compilation (#2212, #2213) + +### Miscellaneous +* `catch_discover_tests` should handle escaped semicolon (`;`) better (#2214, #2215) + + +## 2.13.5 + +### Improvements +* Detection of MAC and IPHONE platforms has been improved (#2140, #2157) +* Added workaround for bug in XLC 16.1.0.1 (#2155) +* Add detection for LCC when it is masquerading as GCC (#2199) +* Modified posix signal handling so it supports newer libcs (#2178) + * `MINSIGSTKSZ` was no longer usable in constexpr context. + +### Fixes +* Fixed compilation of benchmarking when `min` and `max` macros are defined (#2159) + * Including `windows.h` without `NOMINMAX` remains a really bad idea, don't do it + +### Miscellaneous +* The check whether Catch2 is being built as a subproject is now more reliable (#2202, #2204) + * The problem was that if the variable name used internally was defined the project including Catch2 as subproject, it would not be properly overwritten for Catch2's CMake. + + +## 2.13.4 + +### Improvements +* Improved the hashing algorithm used for shuffling test cases (#2070) + * `TEST_CASE`s that differ only in the last character should be properly shuffled + * Note that this means that v2.13.4 gives you a different order of test cases than 2.13.3, even given the same seed. + +### Miscellaneous +* Deprecated `ParseAndAddCatchTests` CMake integration (#2092) + * It is impossible to implement it properly for all the different test case variants Catch2 provides, and there are better options provided. + * Use `catch_discover_tests` instead, which uses runtime information about available tests. +* Fixed bug in `catch_discover_tests` that would cause it to fail when used in specific project structures (#2119) +* Added Bazel build file +* Added an experimental static library target to CMake + + +## 2.13.3 + +### Fixes +* Fixed possible infinite loop when combining generators with section filter (`-c` option) (#2025) + +### Miscellaneous +* Fixed `ParseAndAddCatchTests` not finding `TEST_CASE`s without tags (#2055, #2056) +* `ParseAndAddCatchTests` supports `CMP0110` policy for changing behaviour of `add_test` (#2057) + * This was the shortlived change in CMake 3.18.0 that temporarily broke `ParseAndAddCatchTests` + + +## 2.13.2 + +### Improvements +* Implemented workaround for AppleClang shadowing bug (#2030) +* Implemented workaround for NVCC ICE (#2005, #2027) + +### Fixes +* Fixed detection of `std::uncaught_exceptions` support under non-msvc platforms (#2021) +* Fixed the experimental stdout/stderr capture under Windows (#2013) + +### Miscellaneous +* `catch_discover_tests` has been improved significantly (#2023, #2039) + * You can now specify which reporter should be used + * You can now modify where the output will be written + * `WORKING_DIRECTORY` setting is respected +* `ParseAndAddCatchTests` now supports `TEMPLATE_TEST_CASE` macros (#2031) +* Various documentation fixes and improvements (#2022, #2028, #2034) + + +## 2.13.1 + +### Improvements +* `ParseAndAddCatchTests` handles CMake v3.18.0 correctly (#1984) +* Improved autodetection of `std::byte` (#1992) +* Simplified implementation of templated test cases (#2007) + * This should have a tiny positive effect on its compilation throughput + +### Fixes +* Automatic stringification of ranges handles sentinel ranges properly (#2004) + + +## 2.13.0 + +### Improvements +* `GENERATE` can now follow a `SECTION` at the same level of nesting (#1938) + * The `SECTION`(s) before the `GENERATE` will not be run multiple times, the following ones will. +* Added `-D`/`--min-duration` command line flag (#1910) + * If a test takes longer to finish than the provided value, its name and duration will be printed. + * This flag is overriden by setting `-d`/`--duration`. + +### Fixes +* `TAPReporter` no longer skips successful assertions (#1983) + + +## 2.12.4 + +### Improvements +* Added support for MacOS on ARM (#1971) + + +## 2.12.3 + +### Fixes +* `GENERATE` nested in a for loop no longer creates multiple generators (#1913) +* Fixed copy paste error breaking `TEMPLATE_TEST_CASE_SIG` for 6 or more arguments (#1954) +* Fixed potential UB when handling non-ASCII characters in CLI args (#1943) + +### Improvements +* There can be multiple calls to `GENERATE` on a single line +* Improved `fno-except` support for platforms that do not provide shims for exception-related std functions (#1950) + * E.g. the Green Hills C++ compiler +* XmlReporter now also reports test-case-level statistics (#1958) + * This is done via a new element, `OverallResultsCases` + +### Miscellaneous +* Added `.clang-format` file to the repo (#1182, #1920) +* Rewrote contributing docs + * They should explain the different levels of testing and so on much better + + +## 2.12.2 + +### Fixes +* Fixed compilation failure if `is_range` ADL found deleted function (#1929) +* Fixed potential UB in `CAPTURE` if the expression contained non-ASCII characters (#1925) + +### Improvements +* `std::result_of` is not used if `std::invoke_result` is available (#1934) +* JUnit reporter writes out `status` attribute for tests (#1899) +* Suppresed clang-tidy's `hicpp-vararg` warning (#1921) + * Catch2 was already suppressing the `cppcoreguidelines-pro-type-vararg` alias of the warning + + +## 2.12.1 + +### Fixes +* Vector matchers now support initializer list literals better + +### Improvements +* Added support for `^` (bitwise xor) to `CHECK` and `REQUIRE` + + + +## 2.12.0 + +### Improvements +* Running tests in random order (`--order rand`) has been reworked significantly (#1908) + * Given same seed, all platforms now produce the same order + * Given same seed, the relative order of tests does not change if you select only a subset of them +* Vector matchers support custom allocators (#1909) +* `|` and `&` (bitwise or and bitwise and) are now supported in `CHECK` and `REQUIRE` + * The resulting type must be convertible to `bool` + +### Fixes +* Fixed computation of benchmarking column widths in ConsoleReporter (#1885, #1886) +* Suppressed clang-tidy's `cppcoreguidelines-pro-type-vararg` in assertions (#1901) + * It was a false positive trigered by the new warning support workaround +* Fixed bug in test specification parser handling of OR'd patterns using escaping (#1905) + +### Miscellaneous +* Worked around IBM XL's codegen bug (#1907) + * It would emit code for _destructors_ of temporaries in an unevaluated context +* Improved detection of stdlib's support for `std::uncaught_exceptions` (#1911) + + + +## 2.11.3 + +### Fixes +* Fixed compilation error caused by lambdas in assertions under MSVC + + +## 2.11.2 + +### Improvements +* GCC and Clang now issue warnings for suspicious code in assertions (#1880) + * E.g. `REQUIRE( int != unsigned int )` will now issue mixed signedness comparison warning + * This has always worked on MSVC, but it now also works for GCC and current Clang versions +* Colorization of "Test filters" output should be more robust now +* `--wait-for-keypress` now also accepts `never` as an option (#1866) +* Reporters no longer round-off nanoseconds when reporting benchmarking results (#1876) +* Catch2's debug break now supports iOS while using Thumb instruction set (#1862) +* It is now possible to customize benchmark's warm-up time when running the test binary (#1844) + * `--benchmark-warmup-time {ms}` +* User can now specify how Catch2 should break into debugger (#1846) + +### Fixes +* Fixes missing `` include in benchmarking (#1831) +* Fixed missing `` include in benchmarking (#1874) +* Hidden test cases are now also tagged with `[!hide]` as per documentation (#1847) +* Detection of whether libc provides `std::nextafter` has been improved (#1854) +* Detection of `wmain` no longer incorrectly looks for `WIN32` macro (#1849) + * Now it just detects Windows platform +* Composing already-composed matchers no longer modifies the partially-composed matcher expression + * This bug has been present for the last ~2 years and nobody reported it + + + +## 2.11.1 + +### Improvements +* Breaking into debugger is supported on iOS (#1817) +* `google-build-using-namespace` clang-tidy warning is suppressed (#1799) + +### Fixes +* Clang on Windows is no longer assumed to implement MSVC's traditional preprocessor (#1806) +* `ObjectStorage` now behaves properly in `const` contexts (#1820) +* `GENERATE_COPY(a, b)` now compiles properly (#1809, #1815) +* Some more cleanups in the benchmarking support + + + +## 2.11.0 + +### Improvements +* JUnit reporter output now contains more details in case of failure (#1347, #1719) +* Added SonarQube Test Data reporter (#1738) + * It is in a separate header, just like the TAP, Automake, and TeamCity reporters +* `range` generator now allows floating point numbers (#1776) +* Reworked part of internals to increase throughput + + +### Fixes +* The single header version should contain full benchmarking support (#1800) +* `[.foo]` is now properly parsed as `[.][foo]` when used on the command line (#1798) +* Fixed compilation of benchmarking on platforms where `steady_clock::period` is not `std::nano` (#1794) + + + +## 2.10.2 + +### Improvements +* Catch2 will now compile on platform where `INFINITY` is double (#1782) + + +### Fixes +* Warning suppressed during listener registration will no longer leak + + + +## 2.10.1 + +### Improvements +* Catch2 now guards itself against `min` and `max` macros from `windows.h` (#1772) +* Templated tests will now compile with ICC (#1748) +* `WithinULP` matcher now uses scientific notation for stringification (#1760) + + +### Fixes +* Templated tests no longer trigger `-Wunused-templates` (#1762) +* Suppressed clang-analyzer false positive in context getter (#1230, #1735) + + +### Miscellaneous +* CMake no longer prohibits in-tree build when Catch2 is used as a subproject (#1773, #1774) + + + +## 2.10.0 + +### Fixes +* `TEMPLATE_LIST_TEST_CASE` now properly handles non-copyable and non-movable types (#1729) +* Fixed compilation error on Solaris caused by a system header defining macro `TT` (#1722, #1723) +* `REGISTER_ENUM` will now fail at compilation time if the registered enum is too large +* Removed use of `std::is_same_v` in C++17 mode (#1757) +* Fixed parsing of escaped special characters when reading test specs from a file (#1767, #1769) + + +### Improvements +* Trailing and leading whitespace in test/section specs are now ignored. +* Writing to Android debug log now uses `__android_log_write` instead of `__android_log_print` +* Android logging support can now be turned on/off at compile time (#1743) + * The toggle is `CATCH_CONFIG_ANDROID_LOGWRITE` +* Added a generator that returns elements of a range + * Use via `from_range(from, to)` or `from_range(container)` +* Added support for CRTs that do not provide `std::nextafter` (#1739) + * They must still provide global `nextafter{f,l,}` + * Enabled via `CATCH_CONFIG_GLOBAL_NEXTAFTER` +* Special cased `Approx(inf)` not to match non-infinite values + * Very strictly speaking this might be a breaking change, but it should match user expectations better +* The output of benchmarking through the Console reporter when `--benchmark-no-analysis` is set is now much simpler (#1768) +* Added a matcher that can be used for checking an exceptions message (#1649, #1728) + * The matcher helper function is called `Message` + * The exception must publicly derive from `std::exception` + * The matching is done exactly, including case and whitespace +* Added a matcher that can be used for checking relative equality of floating point numbers (#1746) + * Unlike `Approx`, it considers both sides when determining the allowed margin + * Special cases `NaN` and `INFINITY` to match user expectations + * The matcher helper function is called `WithinRel` +* The ULP matcher now allows for any possible distance between the two numbers +* The random number generators now use Catch-global instance of RNG (#1734, #1736) + * This means that nested random number generators actually generate different numbers + + +### Miscellaneous +* In-repo PNGs have been optimized to lower overhead of using Catch2 via git clone +* Catch2 now uses its own implementation of the URBG concept + * In the future we also plan to use our own implementation of the distributions from `` to provide cross-platform repeatability of random results + + + +## 2.9.2 + +### Fixes +* `ChunkGenerator` can now be used with chunks of size 0 (#1671) +* Nested subsections are now run properly when specific section is run via the `-c` argument (#1670, #1673) +* Catch2 now consistently uses `_WIN32` to detect Windows platform (#1676) +* `TEMPLATE_LIST_TEST_CASE` now support non-default constructible type lists (#1697) +* Fixed a crash in the XMLReporter when a benchmark throws exception during warmup (#1706) +* Fixed a possible infinite loop in CompactReporter (#1715) +* Fixed `-w NoTests` returning 0 even when no tests were matched (#1449, #1683, #1684) +* Fixed matcher compilation under Obj-C++ (#1661) + +### Improvements +* `RepeatGenerator` and `FixedValuesGenerator` now fail to compile when used with `bool` (#1692) + * Previously they would fail at runtime. +* Catch2 now supports Android's debug logging for its debug output (#1710) +* Catch2 now detects and configures itself for the RTX platform (#1693) + * You still need to pass `--benchmark-no-analysis` if you are using benchmarking under RTX +* Removed a "storage class is not first" warning when compiling Catch2 with PGI compiler (#1717) + +### Miscellaneous +* Documentation now contains indication when a specific feature was introduced (#1695) + * These start with Catch2 v2.3.0, (a bit over a year ago). + * `docs/contributing.md` has been updated to provide contributors guidance on how to add these to newly written documentation +* Various other documentation improvements + * ToC fixes + * Documented `--order` and `--rng-seed` command line options + * Benchmarking documentation now clearly states that it requires opt-in + * Documented `CATCH_CONFIG_CPP17_OPTIONAL` and `CATCH_CONFIG_CPP17_BYTE` macros + * Properly documented built-in vector matchers + * Improved `*_THROWS_MATCHES` documentation a bit +* CMake config file is now arch-independent even if `CMAKE_SIZEOF_VOID_P` is in CMake cache (#1660) +* `CatchAddTests` now properly escapes `[` and `]` in test names (#1634, #1698) +* Reverted `CatchAddTests` adding tags as CTest labels (#1658) + * The script broke when test names were too long + * Overwriting `LABELS` caused trouble for users who set them manually + * CMake does not let users append to `LABELS` if the test name has spaces + + +## 2.9.1 + +### Fixes +* Fix benchmarking compilation failure in files without `CATCH_CONFIG_EXTERNAL_INTERFACES` (or implementation) + + +## 2.9.0 + +### Improvements +* The experimental benchmarking support has been replaced by integrating Nonius code (#1616) + * This provides a much more featurefull micro-benchmarking support. + * Due to the compilation cost, it is disabled by default. See the documentation for details. + * As far as backwards compatibility is concerned, this feature is still considered experimental in that we might change the interface based on user feedback. +* `WithinULP` matcher now shows the acceptable range (#1581) +* Template test cases now support type lists (#1627) + + +## 2.8.0 + +### Improvements +* Templated test cases no longer check whether the provided types are unique (#1628) + * This allows you to e.g. test over `uint32_t`, `uint64_t`, and `size_t` without compilation failing +* The precision of floating point stringification can be modified by user (#1612, #1614) +* We now provide `REGISTER_ENUM` convenience macro for generating `StringMaker` specializations for enums + * See the "String conversion" documentation for details +* Added new set of macros for template test cases that enables the use of NTTPs (#1531, #1609) + * See "Test cases and sections" documentation for details + +### Fixes +* `UNSCOPED_INFO` macro now has a prefixed/disabled/prefixed+disabled versions (#1611) +* Reporting errors at startup should no longer cause a segfault under certain circumstances (#1626) + + +### Miscellaneous +* CMake will now prevent you from attempting in-tree build (#1636, #1638) + * Previously it would break with an obscure error message during the build step + + +## 2.7.2 + +### Improvements +* Added an approximate vector matcher (#1499) + +### Fixes +* Filters will no longer be shown if there were none +* Fixed compilation error when using Homebrew GCC on OS X (#1588, #1589) +* Fixed the console reporter not showing messages that start with a newline (#1455, #1470) +* Modified JUnit reporter's output so that rng seed and filters are reported according to the JUnit schema (#1598) +* Fixed some obscure warnings and static analysis passes + +### Miscellaneous +* Various improvements to `ParseAndAddCatchTests` (#1559, #1601) + * When a target is parsed, it receives `ParseAndAddCatchTests_TESTS` property which summarizes found tests + * Fixed problem with tests not being found if the `OptionalCatchTestLauncher` variables is used + * Including the script will no longer forcefully modify `CMAKE_MINIMUM_REQUIRED_VERSION` + * CMake object libraries are ignored when parsing to avoid needless warnings +* `CatchAddTests` now adds test's tags to their CTest labels (#1600) +* Added basic CPack support to our build + +## 2.7.1 + +### Improvements +* Reporters now print out the filters applied to test cases (#1550, #1585) +* Added `GENERATE_COPY` and `GENERATE_REF` macros that can use variables inside the generator expression + * Because of the significant danger of lifetime issues, the default `GENERATE` macro still does not allow variables +* The `map` generator helper now deduces the mapped return type (#1576) + +### Fixes +* Fixed ObjC++ compilation (#1571) +* Fixed test tag parsing so that `[.foo]` is now parsed as `[.][foo]`. +* Suppressed warning caused by the Windows headers defining SE codes in different manners (#1575) + +## 2.7.0 + +### Improvements +* `TEMPLATE_PRODUCT_TEST_CASE` now uses the resulting type in the name, instead of the serial number (#1544) +* Catch2's single header is now strictly ASCII (#1542) +* Added generator for random integral/floating point types + * The types are inferred within the `random` helper +* Added back RangeGenerator (#1526) + * RangeGenerator returns elements within a certain range +* Added ChunkGenerator generic transform (#1538) + * A ChunkGenerator returns the elements from different generator in chunks of n elements +* Added `UNSCOPED_INFO` (#415, #983, #1522) + * This is a variant of `INFO` that lives until next assertion/end of the test case. + + +### Fixes +* All calls to C stdlib functions are now `std::` qualified (#1541) + * Code brought in from Clara was also updated. +* Running tests will no longer open the specified output file twice (#1545) + * This would cause trouble when the file was not a file, but rather a named pipe + * Fixes the CLion/Resharper integration with Catch +* Fixed `-Wunreachable-code` occurring with (old) ccache+cmake+clang combination (#1540) +* Fixed `-Wdefaulted-function-deleted` warning with Clang 8 (#1537) +* Catch2's type traits and helpers are now properly namespaced inside `Catch::` (#1548) +* Fixed std{out,err} redirection for failing test (#1514, #1525) + * Somehow, this bug has been present for well over a year before it was reported + + +### Contrib +* `ParseAndAddCatchTests` now properly escapes commas in the test name + + + +## 2.6.1 + +### Improvements +* The JUnit reporter now also reports random seed (#1520, #1521) + +### Fixes +* The TAP reporter now formats comments with test name properly (#1529) +* `CATCH_REQUIRE_THROWS`'s internals were unified with `REQUIRE_THROWS` (#1536) + * This fixes a potential `-Wunused-value` warning when used +* Fixed a potential segfault when using any of the `--list-*` options (#1533, #1534) + + +## 2.6.0 + +**With this release the data generator feature is now fully supported.** + + +### Improvements +* Added `TEMPLATE_PRODUCT_TEST_CASE` (#1454, #1468) + * This allows you to easily test various type combinations, see documentation for details +* The error message for `&&` and `||` inside assertions has been improved (#1273, #1480) +* The error message for chained comparisons inside assertions has been improved (#1481) +* Added `StringMaker` specialization for `std::optional` (#1510) +* The generator interface has been redone once again (#1516) + * It is no longer considered experimental and is fully supported + * The new interface supports "Input" generators + * The generator documentation has been fully updated + * We also added 2 generator examples + + +### Fixes +* Fixed `-Wredundant-move` on newer Clang (#1474) +* Removed unreachable mentions `std::current_exception`, `std::rethrow_exception` in no-exceptions mode (#1462) + * This should fix compilation with IAR +* Fixed missing `` include (#1494) +* Fixed various static analysis warnings + * Unrestored stream state in `XmlWriter` (#1489) + * Potential division by zero in `estimateClockResolution` (#1490) + * Uninitialized member in `RunContext` (#1491) + * `SourceLineInfo` move ops are now marked `noexcept` + * `CATCH_BREAK_INTO_DEBUGGER` is now always a function +* Fix double run of a test case if user asks for a specific section (#1394, #1492) +* ANSI colour code output now respects `-o` flag and writes to the file as well (#1502) +* Fixed detection of `std::variant` support for compilers other than Clang (#1511) + + +### Contrib +* `ParseAndAddCatchTests` has learned how to use `DISABLED` CTest property (#1452) +* `ParseAndAddCatchTests` now works when there is a whitspace before the test name (#1493) + + +### Miscellaneous +* We added new issue templates for reporting issues on GitHub +* `contributing.md` has been updated to reflect the current test status (#1484) + + + +## 2.5.0 + +### Improvements +* Added support for templated tests via `TEMPLATE_TEST_CASE` (#1437) + + +### Fixes +* Fixed compilation of `PredicateMatcher` by removing partial specialization of `MatcherMethod` +* Listeners now implicitly support any verbosity (#1426) +* Fixed compilation with Embarcadero builder by introducing `Catch::isnan` polyfill (#1438) +* Fixed `CAPTURE` asserting for non-trivial captures (#1436, #1448) + + +### Miscellaneous +* We should now be providing first party Conan support via https://bintray.com/catchorg/Catch2 (#1443) +* Added new section "deprecations and planned changes" to the documentation + * It contains summary of what is deprecated and might change with next major version +* From this release forward, the released headers should be pgp signed (#430) + * KeyID `E29C 46F3 B8A7 5028 6079 3B7D ECC9 C20E 314B 2360` + * or https://codingnest.com/files/horenmar-publickey.asc + + +## 2.4.2 + +### Improvements +* XmlReporter now also outputs the RNG seed that was used in a run (#1404) +* `Catch::Session::applyCommandLine` now also accepts `wchar_t` arguments. + * However, Catch2 still does not support unicode. +* Added `STATIC_REQUIRE` macro (#1356, #1362) +* Catch2's singleton's are now cleaned up even if tests are run (#1411) + * This is mostly useful as a FP prevention for users who define their own main. +* Specifying an invalid reporter via `-r` is now reported sooner (#1351, #1422) + + +### Fixes +* Stringification no longer assumes that `char` is signed (#1399, #1407) + * This caused a `Wtautological-compare` warning. +* SFINAE for `operator<<` no longer sees different overload set than the actual insertion (#1403) + + +### Contrib +* `catch_discover_tests` correctly adds tests with comma in name (#1327, #1409) +* Added a new customization point in how the tests are launched to `catch_discover_tests` + + +## 2.4.1 + +### Improvements +* Added a StringMaker for `std::(w)string_view` (#1375, #1376) +* Added a StringMaker for `std::variant` (#1380) + * This one is disabled by default to avoid increased compile-time drag +* Added detection for cygwin environment without `std::to_string` (#1396, #1397) + +### Fixes +* `UnorderedEqualsMatcher` will no longer accept erroneously accept +vectors that share suffix, but are not permutation of the desired vector +* Abort after (`-x N`) can no longer be overshot by nested `REQUIRES` and +subsequently ignored (#1391, #1392) + + +## 2.4.0 + +**This release brings two new experimental features, generator support +and a `-fno-exceptions` support. Being experimental means that they +will not be subject to the usual stability guarantees provided by semver.** + +### Improvements +* Various small runtime performance improvements +* `CAPTURE` macro is now variadic +* Added `AND_GIVEN` macro (#1360) +* Added experimental support for data generators + * See [their documentation](generators.md) for details +* Added support for compiling and running Catch without exceptions + * Doing so limits the functionality somewhat + * Look [into the documentation](configuration.md#disablingexceptions) for details + +### Fixes +* Suppressed `-Wnon-virtual-dtor` warnings in Matchers (#1357) +* Suppressed `-Wunreachable-code` warnings in floating point matchers (#1350) + +### CMake +* It is now possible to override which Python is used to run Catch's tests (#1365) +* Catch now provides infrastructure for adding tests that check compile-time configuration +* Catch no longer tries to install itself when used as a subproject (#1373) +* Catch2ConfigVersion.cmake is now generated as arch-independent (#1368) + * This means that installing Catch from 32-bit machine and copying it to 64-bit one works + * This fixes conan installation of Catch + + +## 2.3.0 + +**This release changes the include paths provided by our CMake and +pkg-config integration. The proper include path for the single-header +when using one of the above is now ``. This change +also necessitated changes to paths inside the repository, so that the +single-header version is now at `single_include/catch2/catch.hpp`, rather +than `single_include/catch.hpp`.** + + + +### Fixes +* Fixed Objective-C++ build +* `-Wunused-variable` suppression no longer leaks from Catch's header under Clang +* Implementation of the experimental new output capture can now be disabled (#1335) + * This allows building Catch2 on platforms that do not provide things like `dup` or `tmpfile`. +* The JUnit and XML reporters will no longer skip over successful tests when running without `-s` (#1264, #1267, #1310) + * See improvements for more details + +### Improvements +* pkg-config and CMake integration has been rewritten + * If you use them, the new include path is `#include ` + * CMake installation now also installs scripts from `contrib/` + * For details see the [new documentation](cmake-integration.md#top) +* Reporters now have a new customization point, `ReporterPreferences::shouldReportAllAssertions` + * When this is set to `false` and the tests are run without `-s`, passing assertions are not sent to the reporter. + * Defaults to `false`. +* Added `DYNAMIC_SECTION`, a section variant that constructs its name using stream + * This means that you can do `DYNAMIC_SECTION("For X := " << x)`. + + +## 2.2.3 + +**To fix some of the bugs, some behavior had to change in potentially breaking manner.** +**This means that even though this is a patch release, it might not be a drop-in replacement.** + +### Fixes +* Listeners are now called before reporter + * This was always documented to be the case, now it actually works that way +* Catch's commandline will no longer accept multiple reporters + * This was done because multiple reporters never worked properly and broke things in non-obvious ways + * **This has potential to be a breaking change** +* MinGW is now detected as Windows platform w/o SEH support (#1257) + * This means that Catch2 no longer tries to use POSIX signal handling when compiled with MinGW +* Fixed potential UB in parsing tags using non-ASCII characters (#1266) + * Note that Catch2 still supports only ASCII test names/tags/etc +* `TEST_CASE_METHOD` can now be used on classnames containing commas (#1245) + * You have to enclose the classname in extra set of parentheses +* Fixed insufficient alt stack size for POSIX signal handling (#1225) +* Fixed compilation error on Android due to missing `std::to_string` in C++11 mode (#1280) +* Fixed the order of user-provided `FALLBACK_STRINGIFIER` in stringification machinery (#1024) + * It was intended to be replacement for built-in fallbacks, but it was used _after_ them. + * **This has potential to be a breaking change** +* Fixed compilation error when a type has an `operator<<` with templated lhs (#1285, #1306) + +### Improvements +* Added a new, experimental, output capture (#1243) + * This capture can also redirect output written via C apis, e.g. `printf` + * To opt-in, define `CATCH_CONFIG_EXPERIMENTAL_REDIRECT` in the implementation file +* Added a new fallback stringifier for classes derived from `std::exception` + * Both `StringMaker` specialization and `operator<<` overload are given priority + +### Miscellaneous +* `contrib/` now contains dbg scripts that skip over Catch's internals (#904, #1283) + * `gdbinit` for gdb `lldbinit` for lldb +* `CatchAddTests.cmake` no longer strips whitespace from tests (#1265, #1281) +* Online documentation now describes `--use-colour` option (#1263) + + +## 2.2.2 + +### Fixes +* Fixed bug in `WithinAbs::match()` failing spuriously (#1228) +* Fixed clang-tidy diagnostic about virtual call in destructor (#1226) +* Reduced the number of GCC warnings suppression leaking out of the header (#1090, #1091) + * Only `-Wparentheses` should be leaking now +* Added upper bound on the time benchmark timer calibration is allowed to take (#1237) + * On platforms where `std::chrono::high_resolution_clock`'s resolution is low, the calibration would appear stuck +* Fixed compilation error when stringifying static arrays of `unsigned char`s (#1238) + +### Improvements +* XML encoder now hex-encodes invalid UTF-8 sequences (#1207) + * This affects xml and junit reporters + * Some invalid UTF-8 parts are left as is, e.g. surrogate pairs. This is because certain extensions of UTF-8 allow them, such as WTF-8. +* CLR objects (`T^`) can now be stringified (#1216) + * This affects code compiled as C++/CLI +* Added `PredicateMatcher`, a matcher that takes an arbitrary predicate function (#1236) + * See [documentation for details](https://github.com/catchorg/Catch2/blob/devel/docs/matchers.md) + +### Others +* Modified CMake-installed pkg-config to allow `#include `(#1239) + * The plans to standardize on `#include ` are still in effect + + +## 2.2.1 + +### Fixes +* Fixed compilation error when compiling Catch2 with `std=c++17` against libc++ (#1214) + * Clara (Catch2's CLI parsing library) used `std::optional` without including it explicitly +* Fixed Catch2 return code always being 0 (#1215) + * In the words of STL, "We feel superbad about letting this in" + + +## 2.2.0 + +### Fixes +* Hidden tests are not listed by default when listing tests (#1175) + * This makes `catch_discover_tests` CMake script work better +* Fixed regression that meant `` could potentially not be included properly (#1197) +* Fixed installing `Catch2ConfigVersion.cmake` when Catch2 is a subproject. + +### Improvements +* Added an option to warn (+ exit with error) when no tests were ran (#1158) + * Use as `-w NoTests` +* Added provisional support for Emscripten (#1114) +* [Added a way to override the fallback stringifier](https://github.com/catchorg/Catch2/blob/devel/docs/configuration.md#fallback-stringifier) (#1024) + * This allows project's own stringification machinery to be easily reused for Catch +* `Catch::Session::run()` now accepts `char const * const *`, allowing it to accept array of string literals (#1031, #1178) + * The embedded version of Clara was bumped to v1.1.3 +* Various minor performance improvements +* Added support for DJGPP DOS crosscompiler (#1206) + + +## 2.1.2 + +### Fixes +* Fixed compilation error with `-fno-rtti` (#1165) +* Fixed NoAssertion warnings +* `operator<<` is used before range-based stringification (#1172) +* Fixed `-Wpedantic` warnings (extra semicolons and binary literals) (#1173) + + +### Improvements +* Added `CATCH_VERSION_{MAJOR,MINOR,PATCH}` macros (#1131) +* Added `BrightYellow` colour for use in reporters (#979) + * It is also used by ConsoleReporter for reconstructed expressions + +### Other changes +* Catch is now exported as a CMake package and linkable target (#1170) + +## 2.1.1 + +### Improvements +* Static arrays are now properly stringified like ranges across MSVC/GCC/Clang +* Embedded newer version of Clara -- v1.1.1 + * This should fix some warnings dragged in from Clara +* MSVC's CLR exceptions are supported + + +### Fixes +* Fixed compilation when comparison operators do not return bool (#1147) +* Fixed CLR exceptions blowing up the executable during translation (#1138) + + +### Other changes +* Many CMake changes + * `NO_SELFTEST` option is deprecated, use `BUILD_TESTING` instead. + * Catch specific CMake options were prefixed with `CATCH_` for namespacing purposes + * Other changes to simplify Catch2's packaging + + + +## 2.1.0 + +### Improvements +* Various performance improvements + * On top of the performance regression fixes +* Experimental support for PCH was added (#1061) +* `CATCH_CONFIG_EXTERNAL_INTERFACES` now brings in declarations of Console, Compact, XML and JUnit reporters +* `MatcherBase` no longer has a pointless second template argument +* Reduced the number of warning suppressions that leak into user's code + * Bugs in g++ 4.x and 5.x mean that some of them have to be left in + + +### Fixes +* Fixed performance regression from Catch classic + * One of the performance improvement patches for Catch classic was not applied to Catch2 +* Fixed platform detection for iOS (#1084) +* Fixed compilation when `g++` is used together with `libc++` (#1110) +* Fixed TeamCity reporter compilation with the single header version + * To fix the underlying issue we will be versioning reporters in single_include folder per release +* The XML reporter will now report `WARN` messages even when not used with `-s` +* Fixed compilation when `VectorContains` matcher was combined using `&&` (#1092) +* Fixed test duration overflowing after 10 seconds (#1125, #1129) +* Fixed `std::uncaught_exception` deprecation warning (#1124) + + +### New features +* New Matchers + * Regex matcher for strings, `Matches`. + * Set-equal matcher for vectors, `UnorderedEquals` + * Floating point matchers, `WithinAbs` and `WithinULP`. +* Stringification now attempts to decompose all containers (#606) + * Containers are objects that respond to ADL `begin(T)` and `end(T)`. + + +### Other changes +* Reporters will now be versioned in the `single_include` folder to ensure their compatibility with the last released version + + + + +## 2.0.1 + +### Breaking changes +* Removed C++98 support +* Removed legacy reporter support +* Removed legacy generator support + * Generator support will come back later, reworked +* Removed `Catch::toString` support + * The new stringification machinery uses `Catch::StringMaker` specializations first and `operator<<` overloads second. +* Removed legacy `SCOPED_MSG` and `SCOPED_INFO` macros +* Removed `INTERNAL_CATCH_REGISTER_REPORTER` + * `CATCH_REGISTER_REPORTER` should be used to register reporters +* Removed legacy `[hide]` tag + * `[.]`, `[.foo]` and `[!hide]` are still supported +* Output into debugger is now colourized +* `*_THROWS_AS(expr, exception_type)` now unconditionally appends `const&` to the exception type. +* `CATCH_CONFIG_FAST_COMPILE` now affects the `CHECK_` family of assertions as well as `REQUIRE_` family of assertions + * This is most noticeable in `CHECK(throws())`, which would previously report failure, properly stringify the exception and continue. Now it will report failure and stop executing current section. +* Removed deprecated matcher utility functions `Not`, `AllOf` and `AnyOf`. + * They are superseded by operators `!`, `&&` and `||`, which are natural and do not have limited arity +* Removed support for non-const comparison operators + * Non-const comparison operators are an abomination that should not exist + * They were breaking support for comparing function to function pointer +* `std::pair` and `std::tuple` are no longer stringified by default + * This is done to avoid dragging in `` and `` headers in common path + * Their stringification can be enabled per-file via new configuration macros +* `Approx` is subtly different and hopefully behaves more as users would expect + * `Approx::scale` defaults to `0.0` + * `Approx::epsilon` no longer applies to the larger of the two compared values, but only to the `Approx`'s value + * `INFINITY == Approx(INFINITY)` returns true + + +### Improvements +* Reporters and Listeners can be defined in files different from the main file + * The file has to define `CATCH_CONFIG_EXTERNAL_INTERFACES` before including catch.hpp. +* Errors that happen during set up before main are now caught and properly reported once main is entered + * If you are providing your own main, you can access and use these as well. +* New assertion macros, *_THROWS_MATCHES(expr, exception_type, matcher) are provided + * As the arguments suggest, these allow you to assert that an expression throws desired type of exception and pass the exception to a matcher. +* JUnit reporter no longer has significantly different output for test cases with and without sections +* Most assertions now support expressions containing commas (ie `REQUIRE(foo() == std::vector{1, 2, 3});`) +* Catch now contains experimental micro benchmarking support + * See `projects/SelfTest/Benchmark.tests.cpp` for examples + * The support being experiment means that it can be changed without prior notice +* Catch uses new CLI parsing library (Clara) + * Users can now easily add new command line options to the final executable + * This also leads to some changes in `Catch::Session` interface +* All parts of matchers can be removed from a TU by defining `CATCH_CONFIG_DISABLE_MATCHERS` + * This can be used to somewhat speed up compilation times +* An experimental implementation of `CATCH_CONFIG_DISABLE` has been added + * Inspired by Doctest's `DOCTEST_CONFIG_DISABLE` + * Useful for implementing tests in source files + * ie for functions in anonymous namespaces + * Removes all assertions + * Prevents `TEST_CASE` registrations + * Exception translators are not registered + * Reporters are not registered + * Listeners are not registered +* Reporters/Listeners are now notified of fatal errors + * This means specific signals or structured exceptions + * The Reporter/Listener interface provides default, empty, implementation to preserve backward compatibility +* Stringification of `std::chrono::duration` and `std::chrono::time_point` is now supported + * Needs to be enabled by a per-file compile time configuration option +* Add `pkg-config` support to CMake install command + + +### Fixes +* Don't use console colour if running in XCode +* Explicit constructor in reporter base class +* Swept out `-Wweak-vtables`, `-Wexit-time-destructors`, `-Wglobal-constructors` warnings +* Compilation for Universal Windows Platform (UWP) is supported + * SEH handling and colorized output are disabled when compiling for UWP +* Implemented a workaround for `std::uncaught_exception` issues in libcxxrt + * These issues caused incorrect section traversals + * The workaround is only partial, user's test can still trigger the issue by using `throw;` to rethrow an exception +* Suppressed C4061 warning under MSVC + + +### Internal changes +* The development version now uses .cpp files instead of header files containing implementation. + * This makes partial rebuilds much faster during development +* The expression decomposition layer has been rewritten +* The evaluation layer has been rewritten +* New library (TextFlow) is used for formatting text to output + + +## Older versions + +### 1.12.x + +#### 1.12.2 +##### Fixes +* Fixed missing include + +#### 1.12.1 + +##### Fixes +* Fixed deprecation warning in `ScopedMessage::~ScopedMessage` +* All uses of `min` or `max` identifiers are now wrapped in parentheses + * This avoids problems when Windows headers define `min` and `max` macros + +#### 1.12.0 + +##### Fixes +* Fixed compilation for strict C++98 mode (ie not gnu++98) and older compilers (#1103) +* `INFO` messages are included in the `xml` reporter output even without `-s` specified. + + +### 1.11.x + +#### 1.11.0 + +##### Fixes +* The original expression in `REQUIRE_FALSE( expr )` is now reporter properly as `!( expr )` (#1051) + * Previously the parentheses were missing and `x != y` would be expanded as `!x != x` +* `Approx::Margin` is now inclusive (#952) + * Previously it was meant and documented as inclusive, but the check itself wasn't + * This means that `REQUIRE( 0.25f == Approx( 0.0f ).margin( 0.25f ) )` passes, instead of fails +* `RandomNumberGenerator::result_type` is now unsigned (#1050) + +##### Improvements +* `__JETBRAINS_IDE__` macro handling is now CLion version specific (#1017) + * When CLion 2017.3 or newer is detected, `__COUNTER__` is used instead of +* TeamCity reporter now explicitly flushes output stream after each report (#1057) + * On some platforms, output from redirected streams would show up only after the tests finished running +* `ParseAndAddCatchTests` now can add test files as dependency to CMake configuration + * This means you do not have to manually rerun CMake configuration step to detect new tests + +### 1.10.x + +#### 1.10.0 + +##### Fixes +* Evaluation layer has been rewritten (backported from Catch 2) + * The new layer is much simpler and fixes some issues (#981) +* Implemented workaround for VS 2017 raw string literal stringification bug (#995) +* Fixed interaction between `[!shouldfail]` and `[!mayfail]` tags and sections + * Previously sections with failing assertions would be marked as failed, not failed-but-ok + +##### Improvements +* Added [libidentify](https://github.com/janwilmans/LibIdentify) support +* Added "wait-for-keypress" option + +### 1.9.x + +#### 1.9.6 + +##### Improvements +* Catch's runtime overhead has been significantly decreased (#937, #939) +* Added `--list-extra-info` cli option (#934). + * It lists all tests together with extra information, ie filename, line number and description. + + + +#### 1.9.5 + +##### Fixes +* Truthy expressions are now reconstructed properly, not as booleans (#914) +* Various warnings are no longer erroneously suppressed in test files (files that include `catch.hpp`, but do not define `CATCH_CONFIG_MAIN` or `CATCH_CONFIG_RUNNER`) (#871) +* Catch no longer fails to link when main is compiled as C++, but linked against Objective-C (#855) +* Fixed incorrect gcc version detection when deciding to use `__COUNTER__` (#928) + * Previously any GCC with minor version less than 3 would be incorrectly classified as not supporting `__COUNTER__`. +* Suppressed C4996 warning caused by upcoming updated to MSVC 2017, marking `std::uncaught_exception` as deprecated. (#927) + +##### Improvements +* CMake integration script now incorporates debug messages and registers tests in an improved way (#911) +* Various documentation improvements + + + +#### 1.9.4 + +##### Fixes +* `CATCH_FAIL` macro no longer causes compilation error without variadic macro support +* `INFO` messages are no longer cleared after being reported once + +##### Improvements and minor changes +* Catch now uses `wmain` when compiled under Windows and `UNICODE` is defined. + * Note that Catch still officially supports only ASCII + +#### 1.9.3 + +##### Fixes +* Completed the fix for (lack of) uint64_t in earlier Visual Studios + +#### 1.9.2 + +##### Improvements and minor changes +* All of `Approx`'s member functions now accept strong typedefs in C++11 mode (#888) + * Previously `Approx::scale`, `Approx::epsilon`, `Approx::margin` and `Approx::operator()` didn't. + + +##### Fixes +* POSIX signals are now disabled by default under QNX (#889) + * QNX does not support current enough (2001) POSIX specification +* JUnit no longer counts exceptions as failures if given test case is marked as ok to fail. +* `Catch::Option` should now have its storage properly aligned. +* Catch no longer attempts to define `uint64_t` on windows (#862) + * This was causing trouble when compiled under Cygwin + +##### Other +* Catch is now compiled under MSVC 2017 using `std:c++latest` (C++17 mode) in CI +* We now provide cmake script that autoregisters Catch tests into ctest. + * See `contrib` folder. + + +#### 1.9.1 + +##### Fixes +* Unexpected exceptions are no longer ignored by default (#885, #887) + + +#### 1.9.0 + + +##### Improvements and minor changes +* Catch no longer attempts to ensure the exception type passed by user in `REQUIRE_THROWS_AS` is a constant reference. + * It was causing trouble when `REQUIRE_THROWS_AS` was used inside templated functions + * This actually reverts changes made in v1.7.2 +* Catch's `Version` struct should no longer be double freed when multiple instances of Catch tests are loaded into single program (#858) + * It is now a static variable in an inline function instead of being an `extern`ed struct. +* Attempt to register invalid tag or tag alias now throws instead of calling `exit()`. + * Because this happen before entering main, it still aborts execution + * Further improvements to this are coming +* `CATCH_CONFIG_FAST_COMPILE` now speeds-up compilation of `REQUIRE*` assertions by further ~15%. + * The trade-off is disabling translation of unexpected exceptions into text. +* When Catch is compiled using C++11, `Approx` is now constructible with anything that can be explicitly converted to `double`. +* Captured messages are now printed on unexpected exceptions + +##### Fixes: +* Clang's `-Wexit-time-destructors` should be suppressed for Catch's internals +* GCC's `-Wparentheses` is now suppressed for all TU's that include `catch.hpp`. + * This is functionally a revert of changes made in 1.8.0, where we tried using `_Pragma` based suppression. This should have kept the suppression local to Catch's assertions, but bugs in GCC's handling of `_Pragma`s in C++ mode meant that it did not always work. +* You can now tell Catch to use C++11-based check when checking whether a type can be streamed to output. + * This fixes cases when an unstreamable type has streamable private base (#877) + * [Details can be found in documentation](configuration.md#catch_config_cpp11_stream_insertable_check) + + +##### Other notes: +* We have added VS 2017 to our CI +* Work on Catch 2 should start soon + + + +### 1.8.x + +#### 1.8.2 + + +##### Improvements and minor changes +* TAP reporter now behaves as if `-s` was always set + * This should be more consistent with the protocol desired behaviour. +* Compact reporter now obeys `-d yes` argument (#780) + * The format is "XXX.123 s: " (3 decimal places are always present). + * Before it did not report the durations at all. +* XML reporter now behaves the same way as Console reporter in regards to `INFO` + * This means it reports `INFO` messages on success, if output on success (`-s`) is enabled. + * Previously it only reported `INFO` messages on failure. +* `CAPTURE(expr)` now stringifies `expr` in the same way assertion macros do (#639) +* Listeners are now finally [documented](event-listeners.md#top). + * Listeners provide a way to hook into events generated by running your tests, including start and end of run, every test case, every section and every assertion. + + +##### Fixes: +* Catch no longer attempts to reconstruct expression that led to a fatal error (#810) + * This fixes possible signal/SEH loop when processing expressions, where the signal was triggered by expression decomposition. +* Fixed (C4265) missing virtual destructor warning in Matchers (#844) +* `std::string`s are now taken by `const&` everywhere (#842). + * Previously some places were taking them by-value. +* Catch should no longer change errno (#835). + * This was caused by libstdc++ bug that we now work around. +* Catch now provides `FAIL_CHECK( ... )` macro (#765). + * Same as `FAIL( ... )`, but does not abort the test. +* Functions like `fabs`, `tolower`, `memset`, `isalnum` are now used with `std::` qualification (#543). +* Clara no longer assumes first argument (binary name) is always present (#729) + * If it is missing, empty string is used as default. +* Clara no longer reads 1 character past argument string (#830) +* Regression in Objective-C bindings (Matchers) fixed (#854) + + +##### Other notes: +* We have added VS 2013 and 2015 to our CI +* Catch Classic (1.x.x) now contains its own, forked, version of Clara (the argument parser). + + + +#### 1.8.1 + +##### Fixes + +Cygwin issue with `gettimeofday` - `#define` was not early enough + +#### 1.8.0 + +##### New features/ minor changes + +* Matchers have new, simpler (and documented) interface. + * Catch provides string and vector matchers. + * For details see [Matchers documentation](matchers.md#top). +* Changed console reporter test duration reporting format (#322) + * Old format: `Some simple comparisons between doubles completed in 0.000123s` + * New format: `xxx.123s: Some simple comparisons between doubles` _(There will always be exactly 3 decimal places)_ +* Added opt-in leak detection under MSVC + Windows (#439) + * Enable it by compiling Catch's main with `CATCH_CONFIG_WINDOWS_CRTDBG` +* Introduced new compile-time flag, `CATCH_CONFIG_FAST_COMPILE`, trading features for compilation speed. + * Moves debug breaks out of tests and into implementation, speeding up test compilation time (~10% on linux). + * _More changes are coming_ +* Added [TAP (Test Anything Protocol)](https://testanything.org/) and [Automake](https://www.gnu.org/software/automake/manual/html_node/Log-files-generation-and-test-results-recording.html#Log-files-generation-and-test-results-recording) reporters. + * These are not present in the default single-include header and need to be downloaded from GitHub separately. + * For details see [documentation about integrating with build systems](build-systems.md#top). +* XML reporter now reports filename as part of the `Section` and `TestCase` tags. +* `Approx` now supports an optional margin of absolute error + * It has also received [new documentation](assertions.md#top). + +##### Fixes +* Silenced C4312 ("conversion from int to 'ClassName *") warnings in the evaluate layer. +* Fixed C4512 ("assignment operator could not be generated") warnings under VS2013. +* Cygwin compatibility fixes + * Signal handling is no longer compiled by default. + * Usage of `gettimeofday` inside Catch should no longer cause compilation errors. +* Improved `-Wparentheses` suppression for gcc (#674) + * When compiled with gcc 4.8 or newer, the suppression is localized to assertions only + * Otherwise it is suppressed for the whole TU +* Fixed test spec parser issue (with escapes in multiple names) + +##### Other +* Various documentation fixes and improvements + + +### 1.7.x + +#### 1.7.2 + +##### Fixes and minor improvements +Xml: + +(technically the first two are breaking changes but are also fixes and arguably break few if any people) +* C-escape control characters instead of XML encoding them (which requires XML 1.1) +* Revert XML output to XML 1.0 +* Can provide stylesheet references by extending the XML reporter +* Added description and tags attributes to XML Reporter +* Tags are closed and the stream flushed more eagerly to avoid stdout interpolation + + +Other: +* `REQUIRE_THROWS_AS` now catches exception by `const&` and reports expected type +* In `SECTION`s the file/ line is now of the `SECTION`. not the `TEST_CASE` +* Added std:: qualification to some functions from C stdlib +* Removed use of RTTI (`dynamic_cast`) that had crept back in +* Silenced a few more warnings in different circumstances +* Travis improvements + +#### 1.7.1 + +##### Fixes: +* Fixed inconsistency in defining `NOMINMAX` and `WIN32_LEAN_AND_MEAN` inside `catch.hpp`. +* Fixed SEH-related compilation error under older MinGW compilers, by making Windows SEH handling opt-in for compilers other than MSVC. + * For specifics, look into the [documentation](configuration.md#top). +* Fixed compilation error under MinGW caused by improper compiler detection. +* Fixed XML reporter sometimes leaving an empty output file when a test ends with signal/structured exception. +* Fixed XML reporter not reporting captured stdout/stderr. +* Fixed possible infinite recursion in Windows SEH. +* Fixed possible compilation error caused by Catch's operator overloads being ambiguous in regards to user-defined templated operators. + +#### 1.7.0 + +##### Features/ Changes: +* Catch now runs significantly faster for passing tests + * Microbenchmark focused on Catch's overhead went from ~3.4s to ~0.7s. + * Real world test using [JSON for Modern C++](https://github.com/nlohmann/json)'s test suite went from ~6m 25s to ~4m 14s. +* Catch can now run specific sections within test cases. + * For now the support is only basic (no wildcards or tags), for details see the [documentation](command-line.md#top). +* Catch now supports SEH on Windows as well as signals on Linux. + * After receiving a signal, Catch reports failing assertion and then passes the signal onto the previous handler. +* Approx can be used to compare values against strong typedefs (available in C++11 mode only). + * Strong typedefs mean types that are explicitly convertible to double. +* CHECK macro no longer stops executing section if an exception happens. +* Certain characters (space, tab, etc) are now pretty printed. + * This means that a `char c = ' '; REQUIRE(c == '\t');` would be printed as `' ' == '\t'`, instead of ` == 9`. + +##### Fixes: +* Text formatting no longer attempts to access out-of-bounds characters under certain conditions. +* THROW family of assertions no longer trigger `-Wunused-value` on expressions containing explicit cast. +* Breaking into debugger under OS X works again and no longer required `DEBUG` to be defined. +* Compilation no longer breaks under certain compiler if a lambda is used inside assertion macro. + +##### Other: +* Catch's CMakeLists now defines install command. +* Catch's CMakeLists now generates projects with warnings enabled. + + +### 1.6.x + +#### 1.6.1 + +##### Features/ Changes: +* Catch now supports breaking into debugger on Linux + +##### Fixes: +* Generators no longer leak memory (generators are still unsupported in general) +* JUnit reporter now reports UTC timestamps, instead of "tbd" +* `CHECK_THAT` macro is now properly defined as `CATCH_CHECK_THAT` when using `CATCH_` prefixed macros + +##### Other: +* Types with overloaded `&&` operator are no longer evaluated twice when used in an assertion macro. +* The use of `__COUNTER__` is suppressed when Catch is parsed by CLion + * This change is not active when compiling a binary +* Approval tests can now be run on Windows +* CMake will now warn if a file is present in the `include` folder but not is not enumerated as part of the project +* Catch now defines `NOMINMAX` and `WIN32_LEAN_AND_MEAN` before including `windows.h` + * This can be disabled if needed, see [documentation](configuration.md#top) for details. + + +#### 1.6.0 + +##### Cmake/ projects: +* Moved CMakeLists.txt to root, made it friendlier for CLion and generating XCode and VS projects, and removed the manually maintained XCode and VS projects. + +##### Features/ Changes: +* Approx now supports `>=` and `<=` +* Can now use `\` to escape chars in test names on command line +* Standardize C++11 feature toggles + +##### Fixes: +* Blue shell colour +* Missing argument to `CATCH_CHECK_THROWS` +* Don't encode extended ASCII in XML +* use `std::shuffle` on more compilers (fixes deprecation warning/error) +* Use `__COUNTER__` more consistently (where available) + +##### Other: +* Tweaks and changes to scripts - particularly for Approval test - to make them more portable + + +## Even Older versions +Release notes were not maintained prior to v1.6.0, but you should be able to work them out from the Git history diff --git a/docs/.vitepress/config.ts b/docs/.vitepress/config.ts new file mode 100644 index 0000000000..2c7f6f29de --- /dev/null +++ b/docs/.vitepress/config.ts @@ -0,0 +1,89 @@ +import { defineConfig } from 'vitepress' + +export default defineConfig({ + lang: 'en-US', + title: 'Catch2', + titleTemplate: 'Catch2', // otherwise false + description: 'Catch2, c++ / cpp unit test open source project.', + appearance: true, // dark mode enabled + base: '/Catch2/', + lastUpdated: true, + // markdown + // https://vitepress.vuejs.org/config/app-configs.html#markdown + markdown: { + theme: 'material-palenight', + lineNumbers: true + }, + + themeConfig: { + nav: [ + { text: 'Contribute', link: 'https://github.com/catchorg/Catch2'} + ], + socialLinks: [ + { icon: 'github', link: 'https://github.com/catchorg/Catch2' }, + //{ icon: 'linkedin', link: 'https://www.linkedin.com/in/ryankert01/'} + ], + sidebar: [ + { + text: 'Guide', + items: [ + { text: 'Introduction', link: '/intro' }, + { text: 'Getting Started', link: '/tutorial' } + ] + }, + { + text: 'Writing tests', + items: [ + { text: 'Assertion macros', link: '/assertions' }, + { text: 'Matchers', link: '/matchers' }, + { text: 'Logging macros', link: '/logging' }, + { text: 'Test cases and sections', link: '/test-cases-and-sections' }, + { text: 'Test fixtures', link: '/test-fixtures' }, + { text: 'Reporters', link: '/reporters' }, + { text: 'Event Listeners', link: '/event-listeners' }, + { text: 'Data Generators', link: '/generators' }, + { text: 'Other macros', link: '/other-macros' }, + { text: 'Micro benchmarking', link: '/benchmarks' } + ] + }, + { + text: 'Fine tuning', + items: [ + { text: 'Supplying your own main()', link: '/own-main' }, + { text: 'Compile-time configuration', link: '/configuration' }, + { text: 'String Conversions', link: '/tostring' }, + ] + }, + { + text: 'Running Command Line', + items: [ + { text: 'Command Line', link: '/command-line' }, + ] + }, + { + text: 'Odds and ends', + items: [ + { text: 'Frequently Asked Questions (FAQ)', link: '/faq' }, + { text: 'Best practices and other tips', link: '/usage-tips' }, + { text: 'CMake integration', link: '/cmake-integration' }, + { text: 'CI and other miscellaneous pieces', link: '/ci-and-misc' }, + { text: 'Known limitations', link: '/limitations' } + + ] + }, + { + text: 'Other', + items: [ + { text: 'Why Catch2?', link: '/why-catch.md' }, + { text: 'Migrating from v2 to v3', link: '/migrate-v2-to-v3' }, + { text: 'Open Source Projects using Catch2', link: '/opensource-users' }, + { text: 'Commercial Projects using Catch2', link: '/commercial-users' }, + { text: 'Contributing', link: '/contributing' }, + { text: 'Release Notes', link: '/release-notes' }, + { text: 'Deprecations and incoming changes', link: '/deprecations' }, + ] + }, + ] + } +}); + diff --git a/CODE_OF_CONDUCT.md b/docs/CODE_OF_CONDUCT.md similarity index 100% rename from CODE_OF_CONDUCT.md rename to docs/CODE_OF_CONDUCT.md diff --git a/docs/assertions.md b/docs/assertions.md index 682eb6e7ce..b5c02fb3c2 100644 --- a/docs/assertions.md +++ b/docs/assertions.md @@ -1,12 +1,7 @@ # Assertion Macros -**Contents**
-[Natural Expressions](#natural-expressions)
-[Exceptions](#exceptions)
-[Matcher expressions](#matcher-expressions)
-[Thread Safety](#thread-safety)
-[Expressions with commas](#expressions-with-commas)
+ Most test frameworks have a large collection of assertion macros to capture all possible conditional forms (```_EQUALS```, ```_NOTEQUALS```, ```_GREATER_THAN``` etc). diff --git a/docs/benchmarks.md b/docs/benchmarks.md index 548913c76f..6beb6aa3b8 100644 --- a/docs/benchmarks.md +++ b/docs/benchmarks.md @@ -50,13 +50,13 @@ Benchmarks can be specified anywhere inside a Catch test case. There is a simple and a slightly more advanced version of the `BENCHMARK` macro. Let's have a look how a naive Fibonacci implementation could be benchmarked: -```c++ +```cpp std::uint64_t Fibonacci(std::uint64_t number) { return number < 2 ? 1 : Fibonacci(number - 1) + Fibonacci(number - 2); } ``` Now the most straight forward way to benchmark this function, is just adding a `BENCHMARK` macro to our test case: -```c++ +```cpp TEST_CASE("Fibonacci") { CHECK(Fibonacci(0) == 1); // some more asserts.. @@ -121,7 +121,7 @@ the macro, some advanced features are available. The contents of the simple benc while the blocks of the advanced benchmarks are invoked exactly twice: once during the estimation phase, and another time during the execution phase. -```c++ +```cpp BENCHMARK("simple"){ return long_computation(); }; BENCHMARK_ADVANCED("advanced")(Catch::Benchmark::Chronometer meter) { @@ -145,7 +145,7 @@ that needs to be done outside the measurement can be done outside the call to The callable object passed in to `measure` can optionally accept an `int` parameter. -```c++ +```cpp meter.measure([](int i) { return long_computation(i); }); ``` @@ -155,7 +155,7 @@ for example. The number of runs can be known beforehand by calling `Catch::Benchmark::Chronometer::runs`; with this one can set up a different instance to be mutated by each run. -```c++ +```cpp std::vector v(meter.runs()); std::fill(v.begin(), v.end(), test_string()); meter.measure([&v](int i) { in_place_escape(v[i]); }); @@ -168,7 +168,7 @@ the resetting code. It is also possible to just provide an argument name to the simple `BENCHMARK` macro to get the same semantics as providing a callable to `meter.measure` with `int` argument: -```c++ +```cpp BENCHMARK("indexed", i){ return long_computation(i); }; ``` @@ -185,7 +185,7 @@ To solve this conundrum, Catch provides class templates that let you manually construct and destroy objects without dynamic allocation and in a way that lets you measure construction and destruction separately. -```c++ +```cpp BENCHMARK_ADVANCED("construct")(Catch::Benchmark::Chronometer meter) { std::vector> storage(meter.runs()); meter.measure([&](int i) { storage[i].construct("thing"); }); @@ -231,7 +231,7 @@ That helps with keeping the code in a natural fashion. Here's an example: -```c++ +```cpp // may measure nothing at all by skipping the long calculation since its // result is not used BENCHMARK("no return"){ long_calculation(); }; diff --git a/docs/cmake-integration.md b/docs/cmake-integration.md index dc3efc9d9f..5b55719a4e 100644 --- a/docs/cmake-integration.md +++ b/docs/cmake-integration.md @@ -27,7 +27,7 @@ If you need custom `main`, you should link only against `Catch2::Catch2`. This means that if Catch2 has been installed on the system, it should be enough to do -```cmake +```bash find_package(Catch2 3 REQUIRED) # These tests can use the Catch2-provided main add_executable(tests test.cpp) @@ -45,7 +45,7 @@ above still works. Another possibility is to use [FetchContent](https://cmake.org/cmake/help/latest/module/FetchContent.html): -```cmake +```bash Include(FetchContent) FetchContent_Declare( @@ -84,7 +84,7 @@ a target. This function works by running the resulting executable with existing tests. #### Usage -```cmake +```bash cmake_minimum_required(VERSION 3.5) project(baz LANGUAGES CXX VERSION 0.0.1) @@ -102,7 +102,7 @@ When using `FetchContent`, `include(Catch)` will fail unless `CMAKE_MODULE_PATH` is explicitly updated to include the extras directory. -```cmake +```bash # ... FetchContent ... # list(APPEND CMAKE_MODULE_PATH ${catch2_SOURCE_DIR}/extras) @@ -113,7 +113,7 @@ catch_discover_tests() #### Customization `catch_discover_tests` can be given several extra argumets: -```cmake +```bash catch_discover_tests(target [TEST_SPEC arg1...] [EXTRA_ARGS arg1...] @@ -216,7 +216,7 @@ parsed are *silently ignored*. #### Usage -```cmake +```bash cmake_minimum_required(VERSION 3.5) project(baz LANGUAGES CXX VERSION 0.0.1) @@ -252,7 +252,7 @@ automatically discovered. Defaults to `OFF`. Optionally, one can specify a launching command to run tests by setting the variable `OptionalCatchTestLauncher` before calling `ParseAndAddCatchTests`. For instance to run some tests using `MPI` and other sequentially, one can write -```cmake +```bash set(OptionalCatchTestLauncher ${MPIEXEC} ${MPIEXEC_NUMPROC_FLAG} ${NUMPROC}) ParseAndAddCatchTests(mpi_foo) unset(OptionalCatchTestLauncher) @@ -370,7 +370,7 @@ If you cannot install Catch2 from a package manager (e.g. Ubuntu 16.04 provides catch only in version 1.2.0) you might want to install it from the repository instead. Assuming you have enough rights, you can just install it to the default location, like so: -``` +```bash $ git clone https://github.com/catchorg/Catch2.git $ cd Catch2 $ cmake -Bbuild -H. -DBUILD_TESTING=OFF @@ -386,7 +386,7 @@ accordingly. ## Installing Catch2 from vcpkg Alternatively, you can build and install Catch2 using [vcpkg](https://github.com/microsoft/vcpkg/) dependency manager: -``` +```bash git clone https://github.com/Microsoft/vcpkg.git cd vcpkg ./bootstrap-vcpkg.sh @@ -397,6 +397,4 @@ cd vcpkg The catch2 port in vcpkg is kept up to date by microsoft team members and community contributors. If the version is out of date, please [create an issue or pull request](https://github.com/Microsoft/vcpkg) on the vcpkg repository. ---- -[Home](Readme.md#top) diff --git a/docs/command-line.md b/docs/command-line.md index 17f2ea0dde..f8ec166574 100644 --- a/docs/command-line.md +++ b/docs/command-line.md @@ -1,584 +1,14 @@ - -# Command line +# Command Line -**Contents**
-[Specifying which tests to run](#specifying-which-tests-to-run)
-[Choosing a reporter to use](#choosing-a-reporter-to-use)
-[Breaking into the debugger](#breaking-into-the-debugger)
-[Showing results for successful tests](#showing-results-for-successful-tests)
-[Aborting after a certain number of failures](#aborting-after-a-certain-number-of-failures)
-[Listing available tests, tags or reporters](#listing-available-tests-tags-or-reporters)
-[Sending output to a file](#sending-output-to-a-file)
-[Naming a test run](#naming-a-test-run)
-[Eliding assertions expected to throw](#eliding-assertions-expected-to-throw)
-[Make whitespace visible](#make-whitespace-visible)
-[Warnings](#warnings)
-[Reporting timings](#reporting-timings)
-[Load test names to run from a file](#load-test-names-to-run-from-a-file)
-[Specify the order test cases are run](#specify-the-order-test-cases-are-run)
-[Specify a seed for the Random Number Generator](#specify-a-seed-for-the-random-number-generator)
-[Identify framework and version according to the libIdentify standard](#identify-framework-and-version-according-to-the-libidentify-standard)
-[Wait for key before continuing](#wait-for-key-before-continuing)
-[Skip all benchmarks](#skip-all-benchmarks)
-[Specify the number of benchmark samples to collect](#specify-the-number-of-benchmark-samples-to-collect)
-[Specify the number of resamples for bootstrapping](#specify-the-number-of-resamples-for-bootstrapping)
-[Specify the confidence-interval for bootstrapping](#specify-the-confidence-interval-for-bootstrapping)
-[Disable statistical analysis of collected benchmark samples](#disable-statistical-analysis-of-collected-benchmark-samples)
-[Specify the amount of time in milliseconds spent on warming up each test](#specify-the-amount-of-time-in-milliseconds-spent-on-warming-up-each-test)
-[Usage](#usage)
-[Specify the section to run](#specify-the-section-to-run)
-[Filenames as tags](#filenames-as-tags)
-[Override output colouring](#override-output-colouring)
-[Test Sharding](#test-sharding)
-[Allow running the binary without tests](#allow-running-the-binary-without-tests)
-[Output verbosity](#output-verbosity)
+visit [Command Line](https://github.com/catchorg/Catch2/blob/devel/docs-others/command-line.md) -Catch works quite nicely without any command line options at all - but for those times when you want greater control the following options are available. -Click one of the following links to take you straight to that option - or scroll on to browse the available options. +stored in `./docs-others`. - ` ...`
- ` -h, -?, --help`
- ` -s, --success`
- ` -b, --break`
- ` -e, --nothrow`
- ` -i, --invisibles`
- ` -o, --out`
- ` -r, --reporter`
- ` -n, --name`
- ` -a, --abort`
- ` -x, --abortx`
- ` -w, --warn`
- ` -d, --durations`
- ` -f, --input-file`
- ` -c, --section`
- ` -#, --filenames-as-tags`
- -
- - ` --list-tests`
- ` --list-tags`
- ` --list-reporters`
- ` --list-listeners`
- ` --order`
- ` --rng-seed`
- ` --libidentify`
- ` --wait-for-keypress`
- ` --skip-benchmarks`
- ` --benchmark-samples`
- ` --benchmark-resamples`
- ` --benchmark-confidence-interval`
- ` --benchmark-no-analysis`
- ` --benchmark-warmup-time`
- ` --colour-mode`
- ` --shard-count`
- ` --shard-index`
- ` --allow-running-no-tests`
- ` --verbosity`
- -
- - - - -## Specifying which tests to run - -
<test-spec> ...
- -Test cases, wildcarded test cases, tags and tag expressions are all passed directly as arguments. Tags are distinguished by being enclosed in square brackets. - -If no test specs are supplied then all test cases, except "hidden" tests, are run. -A test is hidden by giving it any tag starting with (or just) a period (```.```) - or, in the deprecated case, tagged ```[hide]``` or given name starting with `'./'`. To specify hidden tests from the command line ```[.]``` or ```[hide]``` can be used *regardless of how they were declared*. - -Specs must be enclosed in quotes if they contain spaces. If they do not contain spaces the quotes are optional. - -Wildcards consist of the `*` character at the beginning and/or end of test case names and can substitute for any number of any characters (including none). - -Test specs are case insensitive. - -If a spec is prefixed with `exclude:` or the `~` character then the pattern matches an exclusion. This means that tests matching the pattern are excluded from the set - even if a prior inclusion spec included them. Subsequent inclusion specs will take precedence, however. -Inclusions and exclusions are evaluated in left-to-right order. - -Test case examples: - -``` -thisTestOnly Matches the test case called, 'thisTestOnly' -"this test only" Matches the test case called, 'this test only' -these* Matches all cases starting with 'these' -exclude:notThis Matches all tests except, 'notThis' -~notThis Matches all tests except, 'notThis' -~*private* Matches all tests except those that contain 'private' -a* ~ab* abc Matches all tests that start with 'a', except those that - start with 'ab', except 'abc', which is included -~[tag1] Matches all tests except those tagged with '[tag1]' --# [#somefile] Matches all tests from the file 'somefile.cpp' -``` - -Names within square brackets are interpreted as tags. -A series of tags form an AND expression whereas a comma-separated sequence forms an OR expression. e.g.: - -
[one][two],[three]
-This matches all tests tagged `[one]` and `[two]`, as well as all tests tagged `[three]` - -Test names containing special characters, such as `,` or `[` can specify them on the command line using `\`. -`\` also escapes itself. - - -## Choosing a reporter to use - -
-r, --reporter <reporter[::key=value]*>
- -Reporters are how the output from Catch2 (results of assertions, tests, -benchmarks and so on) is formatted and written out. The default reporter -is called the "Console" reporter and is intended to provide relatively -verbose and human-friendly output. - -Reporters are also individually configurable. To pass configuration options -to the reporter, you append `::key=value` to the reporter specification -as many times as you want, e.g. `--reporter xml::out=someFile.xml`. - -The keys must either be prefixed by "X", in which case they are not parsed -by Catch2 and are only passed down to the reporter, or one of options -hardcoded into Catch2. Currently there are only 2, -["out"](#sending-output-to-a-file), and ["colour-mode"](#colour-mode). - -_Note that the reporter might still check the X-prefixed options for -validity, and throw an error if they are wrong._ - -> Support for passing arguments to reporters through the `-r`, `--reporter` flag was introduced in Catch2 3.0.1 - -There are multiple built-in reporters, you can see what they do by using the -[`--list-reporter`](command-line.md#listing-available-tests-tags-or-reporters) -flag. If you need a reporter providing custom format outside of the already -provided ones, look at the ["write your own reporter" part of the reporter -documentation](reporters.md#writing-your-own-reporter). - -This option may be passed multiple times to use multiple (different) -reporters at the same time. See the [reporter documentation](reporters.md#multiple-reporters) -for details on what the resulting behaviour is. Also note that at most one -reporter can be provided without the output-file part of reporter spec. -This reporter will use the "default" output destination, based on -the [`-o`, `--out`](#sending-output-to-a-file) option. - -> Support for using multiple different reporters at the same time was [introduced](https://github.com/catchorg/Catch2/pull/2183) in Catch2 3.0.1 - - -_Note: There is currently no way to escape `::` in the reporter spec, -and thus the reporter names, or configuration keys and values, cannot -contain `::`. As `::` in paths is relatively obscure (unlike ':'), we do -not consider this an issue._ - - - -## Breaking into the debugger -
-b, --break
- -Under most debuggers Catch2 is capable of automatically breaking on a test -failure. This allows the user to see the current state of the test during -failure. - - -## Showing results for successful tests -
-s, --success
- -Usually you only want to see reporting for failed tests. Sometimes it's useful to see *all* the output (especially when you don't trust that that test you just added worked first time!). -To see successful, as well as failing, test results just pass this option. Note that each reporter may treat this option differently. The Junit reporter, for example, logs all results regardless. - - -## Aborting after a certain number of failures -
-a, --abort
--x, --abortx [<failure threshold>]
-
- -If a ```REQUIRE``` assertion fails the test case aborts, but subsequent test cases are still run. -If a ```CHECK``` assertion fails even the current test case is not aborted. - -Sometimes this results in a flood of failure messages and you'd rather just see the first few. Specifying ```-a``` or ```--abort``` on its own will abort the whole test run on the first failed assertion of any kind. Use ```-x``` or ```--abortx``` followed by a number to abort after that number of assertion failures. - - -## Listing available tests, tags or reporters -``` ---list-tests ---list-tags ---list-reporters ---list-listeners -``` - -> The `--list*` options became customizable through reporters in Catch2 3.0.1 - -> The `--list-listeners` option was added in Catch2 3.0.1 - -`--list-tests` lists all registered tests matching specified test spec. -Usually this listing also includes tags, and potentially also other -information, like source location, based on verbosity and reporter's design. - -`--list-tags` lists all tags from registered tests matching specified test -spec. Usually this also includes number of tests cases they match and -similar information. - -`--list-reporters` lists all available reporters and their descriptions. - -`--list-listeners` lists all registered listeners and their descriptions. - -The [`--verbosity` argument](#output-verbosity) modifies the level of detail provided by the default `--list*` options -as follows: - -| Option | `normal` (default) | `quiet` | `high` | -|--------------------|---------------------------------|---------------------|-----------------------------------------| -| `--list-tests` | Test names and tags | Test names only | Same as `normal`, plus source code line | -| `--list-tags` | Tags and counts | Same as `normal` | Same as `normal` | -| `--list-reporters` | Reporter names and descriptions | Reporter names only | Same as `normal` | -| `--list-listeners` | Listener names and descriptions | Same as `normal` | Same as `normal` | - - -## Sending output to a file -
-o, --out <filename>
-
- -Use this option to send all output to a file, instead of stdout. You can -use `-` as the filename to explicitly send the output to stdout (this is -useful e.g. when using multiple reporters). - -> Support for `-` as the filename was introduced in Catch2 3.0.1 - -Filenames starting with "%" (percent symbol) are reserved by Catch2 for -meta purposes, e.g. using `%debug` as the filename opens stream that -writes to platform specific debugging/logging mechanism. - -Catch2 currently recognizes 3 meta streams: - -* `%debug` - writes to platform specific debugging/logging output -* `%stdout` - writes to stdout -* `%stderr` - writes to stderr - -> Support for `%stdout` and `%stderr` was introduced in Catch2 3.0.1 - - - -## Naming a test run -
-n, --name <name for test run>
- -If a name is supplied it will be used by the reporter to provide an overall name for the test run. This can be useful if you are sending to a file, for example, and need to distinguish different test runs - either from different Catch executables or runs of the same executable with different options. If not supplied the name is defaulted to the name of the executable. - - -## Eliding assertions expected to throw -
-e, --nothrow
- -Skips all assertions that test that an exception is thrown, e.g. ```REQUIRE_THROWS```. - -These can be a nuisance in certain debugging environments that may break when exceptions are thrown (while this is usually optional for handled exceptions, it can be useful to have enabled if you are trying to track down something unexpected). - -Sometimes exceptions are expected outside of one of the assertions that tests for them (perhaps thrown and caught within the code-under-test). The whole test case can be skipped when using ```-e``` by marking it with the ```[!throws]``` tag. - -When running with this option any throw checking assertions are skipped so as not to contribute additional noise. Be careful if this affects the behaviour of subsequent tests. - - -## Make whitespace visible -
-i, --invisibles
- -If a string comparison fails due to differences in whitespace - especially leading or trailing whitespace - it can be hard to see what's going on. -This option transforms tabs and newline characters into ```\t``` and ```\n``` respectively when printing. - - -## Warnings -
-w, --warn <warning name>
- -You can think of Catch2's warnings as the equivalent of `-Werror` (`/WX`) -flag for C++ compilers. It turns some suspicious occurences, like a section -without assertions, into errors. Because these might be intended, warnings -are not enabled by default, but user can opt in. - -You can enable multiple warnings at the same time. - -There are currently two warnings implemented: - -``` - NoAssertions // Fail test case / leaf section if no assertions - // (e.g. `REQUIRE`) is encountered. - UnmatchedTestSpec // Fail test run if any of the CLI test specs did - // not match any tests. -``` - -> `UnmatchedTestSpec` was introduced in Catch2 3.0.1. - - - -## Reporting timings -
-d, --durations <yes/no>
- -When set to ```yes``` Catch will report the duration of each test case, in milliseconds. Note that it does this regardless of whether a test case passes or fails. Note, also, the certain reporters (e.g. Junit) always report test case durations regardless of this option being set or not. - -
-D, --min-duration <value>
- -> `--min-duration` was [introduced](https://github.com/catchorg/Catch2/pull/1910) in Catch2 2.13.0 - -When set, Catch will report the duration of each test case that took more -than <value> seconds, in milliseconds. This option is overriden by both -`-d yes` and `-d no`, so that either all durations are reported, or none -are. - - - -## Load test names to run from a file -
-f, --input-file <filename>
- -Provide the name of a file that contains a list of test case names, -one per line. Blank lines are skipped. - -A useful way to generate an initial instance of this file is to combine -the [`--list-tests`](#listing-available-tests-tags-or-reporters) flag with -the [`--verbosity quiet`](#output-verbosity) option. You can also -use test specs to filter this list down to what you want first. - - - -## Specify the order test cases are run -
--order <decl|lex|rand>
- -Test cases are ordered one of three ways: - -### decl -Declaration order (this is the default order if no --order argument is provided). -Tests in the same translation unit are sorted using their declaration orders, -different TUs are sorted in an implementation (linking) dependent order. - - -### lex -Lexicographic order. Tests are sorted by their name, their tags are ignored. - - -### rand - -Randomly ordered. The order is dependent on Catch2's random seed (see -[`--rng-seed`](#rng-seed)), and is subset invariant. What this means -is that as long as the random seed is fixed, running only some tests -(e.g. via tag) does not change their relative order. - -> The subset stability was introduced in Catch2 v2.12.0 - -Since the random order was made subset stable, we promise that given -the same random seed, the order of test cases will be the same across -different platforms, as long as the tests were compiled against identical -version of Catch2. We reserve the right to change the relative order -of tests cases between Catch2 versions, but it is unlikely to happen often. - - - -## Specify a seed for the Random Number Generator -
--rng-seed <'time'|'random-device'|number>
- -Sets the seed for random number generators used by Catch2. These are used -e.g. to shuffle tests when user asks for tests to be in random order. - -Using `time` as the argument asks Catch2 generate the seed through call -to `std::time(nullptr)`. This provides very weak randomness and multiple -runs of the binary can generate the same seed if they are started close -to each other. - -Using `random-device` asks for `std::random_device` to be used instead. -If your implementation provides working `std::random_device`, it should -be preferred to using `time`. Catch2 uses `std::random_device` by default. - - - -## Identify framework and version according to the libIdentify standard -
--libidentify
- -See [The LibIdentify repo for more information and examples](https://github.com/janwilmans/LibIdentify). - - -## Wait for key before continuing -
--wait-for-keypress <never|start|exit|both>
- -Will cause the executable to print a message and wait until the return/ enter key is pressed before continuing - -either before running any tests, after running all tests - or both, depending on the argument. - - -## Skip all benchmarks -
--skip-benchmarks
- -> [Introduced](https://github.com/catchorg/Catch2/issues/2408) in Catch2 3.0.1. - -This flag tells Catch2 to skip running all benchmarks. Benchmarks in this -case mean code blocks in `BENCHMARK` and `BENCHMARK_ADVANCED` macros, not -test cases with the `[!benchmark]` tag. - - -## Specify the number of benchmark samples to collect -
--benchmark-samples <# of samples>
- -> [Introduced](https://github.com/catchorg/Catch2/issues/1616) in Catch2 2.9.0. - -When running benchmarks a number of "samples" is collected. This is the base data for later statistical analysis. -Per sample a clock resolution dependent number of iterations of the user code is run, which is independent of the number of samples. Defaults to 100. - - -## Specify the number of resamples for bootstrapping -
--benchmark-resamples <# of resamples>
- -> [Introduced](https://github.com/catchorg/Catch2/issues/1616) in Catch2 2.9.0. - -After the measurements are performed, statistical [bootstrapping] is performed -on the samples. The number of resamples for that bootstrapping is configurable -but defaults to 100000. Due to the bootstrapping it is possible to give -estimates for the mean and standard deviation. The estimates come with a lower -bound and an upper bound, and the confidence interval (which is configurable but -defaults to 95%). - - [bootstrapping]: http://en.wikipedia.org/wiki/Bootstrapping_%28statistics%29 - - -## Specify the confidence-interval for bootstrapping -
--benchmark-confidence-interval <confidence-interval>
- -> [Introduced](https://github.com/catchorg/Catch2/issues/1616) in Catch2 2.9.0. - -The confidence-interval is used for statistical bootstrapping on the samples to -calculate the upper and lower bounds of mean and standard deviation. -Must be between 0 and 1 and defaults to 0.95. - - -## Disable statistical analysis of collected benchmark samples -
--benchmark-no-analysis
- -> [Introduced](https://github.com/catchorg/Catch2/issues/1616) in Catch2 2.9.0. - -When this flag is specified no bootstrapping or any other statistical analysis is performed. -Instead the user code is only measured and the plain mean from the samples is reported. - - -## Specify the amount of time in milliseconds spent on warming up each test -
--benchmark-warmup-time
- -> [Introduced](https://github.com/catchorg/Catch2/pull/1844) in Catch2 2.11.2. - -Configure the amount of time spent warming up each test. - - -## Usage -
-h, -?, --help
- -Prints the command line arguments to stdout - - - -## Specify the section to run -
-c, --section <section name>
- -To limit execution to a specific section within a test case, use this option one or more times. -To narrow to sub-sections use multiple instances, where each subsequent instance specifies a deeper nesting level. - -E.g. if you have: - -
-TEST_CASE( "Test" ) {
-  SECTION( "sa" ) {
-    SECTION( "sb" ) {
-      /*...*/
-    }
-    SECTION( "sc" ) {
-      /*...*/
+
diff --git a/docs/configuration.md b/docs/configuration.md
index 9fd7f58b6d..7408b5b552 100644
--- a/docs/configuration.md
+++ b/docs/configuration.md
@@ -1,20 +1,7 @@
 
 # Compile-time configuration
 
-**Contents**
-[Prefixing Catch macros](#prefixing-catch-macros)
-[Terminal colour](#terminal-colour)
-[Console width](#console-width)
-[stdout](#stdout)
-[Fallback stringifier](#fallback-stringifier)
-[Default reporter](#default-reporter)
-[Bazel support](#bazel-support)
-[C++11 toggles](#c11-toggles)
-[C++17 toggles](#c17-toggles)
-[Other toggles](#other-toggles)
-[Enabling stringification](#enabling-stringification)
-[Disabling exceptions](#disabling-exceptions)
-[Overriding Catch's debug break (`-b`)](#overriding-catchs-debug-break--b)
+ Catch2 is designed to "just work" as much as possible, and most of the configuration options below are changed automatically during compilation, diff --git a/docs/contributing.md b/docs/contributing.md index addeb5c9a4..97393fb982 100644 --- a/docs/contributing.md +++ b/docs/contributing.md @@ -1,12 +1,7 @@ # Contributing to Catch2 -**Contents**
-[Using Git(Hub)](#using-github)
-[Testing your changes](#testing-your-changes)
-[Writing documentation](#writing-documentation)
-[Writing code](#writing-code)
-[CoC](#coc)
+ So you want to contribute something to Catch2? That's great! Whether it's a bug fix, a new feature, support for additional compilers - or just @@ -305,7 +300,7 @@ guard should be `CATCH_GENERATORS_BAR_HPP_INCLUDED`, and so on. ## CoC -This project has a [CoC](../CODE_OF_CONDUCT.md). Please adhere to it +This project has a [CoC](/CODE_OF_CONDUCT). Please adhere to it while contributing to Catch2. ----------- diff --git a/docs/index.md b/docs/index.md new file mode 100644 index 0000000000..fde89f0cfa --- /dev/null +++ b/docs/index.md @@ -0,0 +1,37 @@ +--- +layout: home + +hero: + name: Catch2 + text: Simple and Natural unit testing framework for C++ + tagline: + actions: + - theme: brand + text: Get Started + link: /intro + - theme: alt + text: View on GitHub + link: https://github.com/catchorg/Catch2 + - theme: alt + text: Discord + link: https://discord.com/invite/4CWS9zD +features: + - icon: ⚡️ + title: Simple and Natural + details: nice!! + - icon: 🖖 + title: Normal C++ code like + details: + - icon: 🛠️ + title: Simple and minimal, always + details: +--- + + \ No newline at end of file diff --git a/README.md b/docs/intro.md similarity index 82% rename from README.md rename to docs/intro.md index 83fdf7b31a..d2ae3cce55 100644 --- a/README.md +++ b/docs/intro.md @@ -1,13 +1,27 @@ + -![Catch2 logo](data/artwork/catch2-logo-small.png) + +# Introducing Catch2! + + + + [![Github Releases](https://img.shields.io/github/release/catchorg/catch2.svg)](https://github.com/catchorg/catch2/releases) + [![Linux build status](https://github.com/catchorg/Catch2/actions/workflows/linux-simple-builds.yml/badge.svg)](https://github.com/catchorg/Catch2/actions/workflows/linux-simple-builds.yml) + [![Linux build status](https://github.com/catchorg/Catch2/actions/workflows/linux-other-builds.yml/badge.svg)](https://github.com/catchorg/Catch2/actions/workflows/linux-other-builds.yml) + [![MacOS build status](https://github.com/catchorg/Catch2/actions/workflows/mac-builds.yml/badge.svg)](https://github.com/catchorg/Catch2/actions/workflows/mac-builds.yml) + [![Build Status](https://ci.appveyor.com/api/projects/status/github/catchorg/Catch2?svg=true&branch=devel)](https://ci.appveyor.com/project/catchorg/catch2) + [![Code Coverage](https://codecov.io/gh/catchorg/Catch2/branch/devel/graph/badge.svg)](https://codecov.io/gh/catchorg/Catch2) + [![Try online](https://img.shields.io/badge/try-online-blue.svg)](https://godbolt.org/z/EdoY15q9G) + [![Join the chat in Discord: https://discord.gg/4CWS9zD](https://img.shields.io/badge/Discord-Chat!-brightgreen.svg)](https://discord.gg/4CWS9zD) @@ -32,7 +46,7 @@ For stable (and documentation-matching) version of Catch2, [go to the `v2.x` branch](https://github.com/catchorg/Catch2/tree/v2.x). For migrating from the v2 releases to v3, you should look at [our -documentation](docs/migrate-v2-to-v3.md#top). It provides a simple +documentation](/migrate-v2-to-v3.md#top). It provides a simple guidelines on getting started, and collects most common migration problems. @@ -40,13 +54,13 @@ problems. ## How to use it This documentation comprises these three parts: -* [Why do we need yet another C++ Test Framework?](docs/why-catch.md#top) -* [Tutorial](docs/tutorial.md#top) - getting started -* [Reference section](docs/Readme.md#top) - all the details +* [Why do we need yet another C++ Test Framework?](/why-catch.md#top) +* [Tutorial](/tutorial.md#top) - getting started +* [Reference section](/Readme.md#top) - all the details ## More * Issues and bugs can be raised on the [Issue tracker on GitHub](https://github.com/catchorg/Catch2/issues) * For discussion or questions please use [our Discord](https://discord.gg/4CWS9zD) -* See who else is using Catch2 in [Open Source Software](docs/opensource-users.md#top) -or [commercially](docs/commercial-users.md#top). +* See who else is using Catch2 in [Open Source Software](/opensource-users.md#top) +or [commercially](/commercial-users.md#top). \ No newline at end of file diff --git a/docs/logging.md b/docs/logging.md index dbd4f912ad..963dbb77d5 100644 --- a/docs/logging.md +++ b/docs/logging.md @@ -90,7 +90,7 @@ Second unscoped info All these macros allow heterogeneous sequences of values to be streaming using the insertion operator (```<<```) in the same way that std::ostream, std::cout, etc support it. E.g.: -```c++ +```cpp INFO( "The number is " << i ); ``` diff --git a/docs/matchers.md b/docs/matchers.md index 0060bfd172..c329e79213 100644 --- a/docs/matchers.md +++ b/docs/matchers.md @@ -1,11 +1,6 @@ # Matchers -**Contents**
-[Using Matchers](#using-matchers)
-[Built-in matchers](#built-in-matchers)
-[Writing custom matchers (old style)](#writing-custom-matchers-old-style)
-[Writing custom matchers (new style)](#writing-custom-matchers-new-style)
Matchers, as popularized by the [Hamcrest](https://en.wikipedia.org/wiki/Hamcrest) framework are an alternative way to write assertions, useful for tests @@ -311,7 +306,7 @@ To combine these into an example, let's say that you want to write a matcher that decides whether the provided argument is a number within certain range. We will call it `IsBetweenMatcher`: -```c++ +```cpp #include #include // ... diff --git a/docs/own-main.md b/docs/own-main.md index 26dfa86da6..673a097f1d 100644 --- a/docs/own-main.md +++ b/docs/own-main.md @@ -1,11 +1,7 @@ # Supplying main() yourself -**Contents**
-[Let Catch2 take full control of args and config](#let-catch2-take-full-control-of-args-and-config)
-[Amending the Catch2 config](#amending-the-catch2-config)
-[Adding your own command line options](#adding-your-own-command-line-options)
-[Version detection](#version-detection)
+ The easiest way to use Catch2 is to use its own `main` function, and let it handle the command line arguments. This is done by linking against @@ -48,7 +44,7 @@ If you want Catch2 to process command line arguments, but also want to programmatically change the resulting configuration of Catch2 run, you can do it in two ways: -```c++ +```cpp int main( int argc, char* argv[] ) { Catch::Session session; // There must be exactly one instance diff --git a/docs/release-notes.md b/docs/release-notes.md index da2c598ceb..fdf3249571 100644 --- a/docs/release-notes.md +++ b/docs/release-notes.md @@ -1,1521 +1,15 @@ # Release notes -**Contents**
-[3.1.0](#310)
-[3.0.1](#301)
-[2.13.7](#2137)
-[2.13.6](#2136)
-[2.13.5](#2135)
-[2.13.4](#2134)
-[2.13.3](#2133)
-[2.13.2](#2132)
-[2.13.1](#2131)
-[2.13.0](#2130)
-[2.12.4](#2124)
-[2.12.3](#2123)
-[2.12.2](#2122)
-[2.12.1](#2121)
-[2.12.0](#2120)
-[2.11.3](#2113)
-[2.11.2](#2112)
-[2.11.1](#2111)
-[2.11.0](#2110)
-[2.10.2](#2102)
-[2.10.1](#2101)
-[2.10.0](#2100)
-[2.9.2](#292)
-[2.9.1](#291)
-[2.9.0](#290)
-[2.8.0](#280)
-[2.7.2](#272)
-[2.7.1](#271)
-[2.7.0](#270)
-[2.6.1](#261)
-[2.6.0](#260)
-[2.5.0](#250)
-[2.4.2](#242)
-[2.4.1](#241)
-[2.4.0](#240)
-[2.3.0](#230)
-[2.2.3](#223)
-[2.2.2](#222)
-[2.2.1](#221)
-[2.2.0](#220)
-[2.1.2](#212)
-[2.1.1](#211)
-[2.1.0](#210)
-[2.0.1](#201)
-[Older versions](#older-versions)
-[Even Older versions](#even-older-versions)
+visit [Release Note](https://github.com/catchorg/Catch2/blob/devel/docs-others/release-notes.md) -## 3.1.0 +stored in `docs-others`. -### Improvements -* Improved suppression of `-Wparentheses` for older GCCs - * Turns out that even GCC 9 does not properly handle `_Pragma`s in the C++ frontend. -* Added type constraints onto `random` generator (#2433) - * These constraints copy what the standard says for the underlying `std::uniform_int_distribution` -* Suppressed -Wunused-variable from nvcc (#2306, #2427) -* Suppressed -Wunused-variable from MinGW (#2132) -* Added All/Any/NoneTrue range matchers (#2319) - * These check that all/any/none of boolean values in a range are true. -* The JUnit reporter now normalizes classnames from C++ namespaces to Java-like namespaces (#2468) - * This provides better support for other JUnit based tools. -* The Bazel support now understands `BAZEL_TEST` environment variable (#2459) - * The `CATCH_CONFIG_BAZEL_SUPPORT` configuration option is also still supported. -* Returned support for compiling Catch2 with GCC 5 (#2448) - * This required removing inherited constructors from Catch2's internals. - * I recommend updating to a newer GCC anyway. -* `catch_discover_tests` now has a new options for setting library load path(s) when running the Catch2 binary (#2467) - - -### Fixes -* Fixed crash when listing listeners without any registered listeners (#2442) -* Fixed nvcc compilation error in constructor benchmarking helper (#2477) -* Catch2's CMakeList supports pre-3.12 CMake again (#2428) - * The gain from requiring CMake 3.12 was very minor, but y'all should really update to newer CMake - - -### Miscellaneous -* Fixed SelfTest build on MinGW (#2447) -* The in-repo conan recipe exports the CMake helper (#2460) -* Added experimental CMake script to showcase using test case sharding together with CTest - * Compared to `catch_discover_tests`, it supports very limited number of options and customization -* Added documentation page on best practices when running Catch2 tests -* Catch2 can be built as a dynamic library (#2397, #2398) - * Note that Catch2 does not have visibility annotations, and you are responsible for ensuring correct visibility built into the resulting library. - - - -## 3.0.1 - -**Catch2 now uses statically compiled library as its distribution model. -This also means that to get all of Catch2's functionality in a test file, -you have to include multiple headers.** - -You probably want to look into the [migration docs](migrate-v2-to-v3.md#top), -which were written to help people coming from v2.x.x versions to the -v3 releases. - - -### FAQ - -* Why is Catch2 moving to separate headers? - * The short answer is future extensibility and scalability. The long answer is complex and can be found on my blog, but at the most basic level, it is that providing single-header distribution is at odds with providing variety of useful features. When Catch2 was distributed in a single header, adding a new Matcher would cause overhead for everyone, but was useful only to a subset of users. This meant that the barrier to entry for new Matchers/Generators/etc is high in single header model, but much smaller in the new model. -* Will Catch2 again distribute single-header version in the future? - * No. But we do provide sqlite-style amalgamated distribution option. This means that you can download just 1 .cpp file and 1 header and place them next to your own sources. However, doing this has downsides similar to using the `catch_all.hpp` header. -* Why the big breaking change caused by replacing `catch.hpp` with `catch_all.hpp`? - * The convenience header `catch_all.hpp` exists for two reasons. One of them is to provide a way for quick migration from Catch2, the second one is to provide a simple way to test things with Catch2. Using it for migration has one drawback in that it is **big**. This means that including it _will_ cause significant compile time drag, and so using it to migrate should be a conscious decision by the user, not something they can just stumble into unknowingly. - - -### (Potentially) Breaking changes -* **Catch2 now uses statically compiled library as its distribution model** - * **Including `catch.hpp` no longer works** -* **Catch2 now uses C++14 as the minimum support language version** -* `ANON_TEST_CASE` has been removed, use `TEST_CASE` with no arguments instead (#1220) -* `--list*` commands no longer have non-zero return code (#1410) -* `--list-test-names-only` has been removed (#1190) - * You should use verbosity-modifiers for `--list-tests` instead -* `--list*` commands are now piped through the reporters - * The top-level reporter interface provides default implementation that works just as the old one - * XmlReporter outputs a machine-parseable XML -* `TEST_CASE` description support has been removed - * If the second argument has text outside tags, the text will be ignored. -* Hidden test cases are no longer included just because they don't match an exclusion tag - * Previously, a `TEST_CASE("A", "[.foo]")` would be included by asking for `~[bar]`. -* `PredicateMatcher` is no longer type erased. - * This means that the type of the provided predicate is part of the `PredicateMatcher`'s type -* `SectionInfo` no longer contains section description as a member (#1319) - * You can still write `SECTION("ShortName", "Long and wordy description")`, but the description is thrown away - * The description type now must be a `const char*` or be implicitly convertible to it -* The `[!hide]` tag has been removed. - * Use `[.]` or `[.foo]` instead. -* Lvalues of composed matchers cannot be composed further -* Uses of `REGISTER_TEST_CASE` macro need to be followed by a semicolon - * This does not change `TEST_CASE` and friends in any way -* `IStreamingReporter::IsMulti` member function was removed - * This is _very_ unlikely to actually affect anyone, as it was default-implemented in the interface, and only used internally -* Various classes not designed for user-extension have been made final - * `ListeningReporter` is now `final` - * Concrete Matchers (e.g. `UnorderedEquals` vector matcher) are now `final` - * All Generators are now `final` -* Matcher namespacing has been redone - * Matcher types are no longer in deeply nested namespaces - * Matcher factory functions are no longer brought into `Catch` namespace - * This means that all public-facing matcher-related functionality is now in `Catch::Matchers` namespace -* Defining `CATCH_CONFIG_MAIN` will no longer create main in that TU. - * Link with `libCatch2Main.a`, or the proper CMake/pkg-config target - * If you want to write custom main, include `catch2/catch_session.hpp` -* `CATCH_CONFIG_EXTERNAL_INTERFACES` has been removed. - * You should instead include the appropriate headers as needed. -* `CATCH_CONFIG_IMPL` has been removed. - * The implementation is now compiled into a static library. -* Event Listener interface has changed - * `TestEventListenerBase` was renamed to `EventListenerBase` - * `EventListenerBase` now directly derives from `IStreamingReporter`, instead of deriving from `StreamingReporterBase` -* `GENERATE` decays its arguments (#2012, #2040) - * This means that `str` in `auto str = GENERATE("aa", "bb", "cc");` is inferred to `char const*` rather than `const char[2]`. -* `--list-*` flags write their output to file specified by the `-o` flag -* Many changes to reporter interfaces - * With the exception of the XmlReporter, the outputs of first party reporters should remain the same - * New pair of events were added - * One obsolete event was removed - * The base class has been renamed - * The built-in reporter class hierarchy has been redone -* Catch2 generates a random seed if one hasn't been specified by the user -* The short flag for `--list-tests`, `-l`, has been removed. - * This is not a commonly used flag and does not need to use up valuable single-letter space. -* The short flag for `--list-tags`, `-t`, has been removed. - * This is not a commonly used flag and does not need to use up valuable single-letter space. -* The `--colour` option has been replaced with `--colour-mode` option - - -### Improvements -* Matchers have been extended with the ability to use different signatures of `match` (#1307, #1553, #1554, #1843) - * This includes having templated `match` member function - * See the [rewritten Matchers documentation](matchers.md#top) for details - * Catch2 currently provides _some_ generic matchers, but there should be more before final release of v3 - * `IsEmpty`, `SizeIs` which check that the range has specific properties - * `Contains`, which checks whether a range contains a specific element - * `AllMatch`, `AnyMatch`, `NoneMatch` range matchers, which apply matchers over a range of elements -* Significant compilation time improvements - * including `catch_test_macros.hpp` is 80% cheaper than including `catch.hpp` -* Some runtime performance optimizations - * In all tested cases the v3 branch was faster, so the table below shows the speedup of v3 to v2 at the same task - - -| task | debug build | release build | -|:------------------------------------------- | ------------:| -------------:| -| Run 1M `REQUIRE(true)` | 1.10 ± 0.01 | 1.02 ± 0.06 | -| Run 100 tests, 3^3 sections, 1 REQUIRE each | 1.27 ± 0.01 | 1.04 ± 0.01 | -| Run 3k tests, no names, no tags | 1.29 ± 0.01 | 1.05 ± 0.01 | -| Run 3k tests, names, tags | 1.49 ± 0.01 | 1.22 ± 0.01 | -| Run 1 out of 3k tests no names, no tags | 1.68 ± 0.02 | 1.19 ± 0.22 | -| Run 1 out of 3k tests, names, tags | 1.79 ± 0.02 | 2.06 ± 0.23 | - - -* POSIX platforms use `gmtime_r`, rather than `gmtime` when constructing a date string (#2008, #2165) -* `--list-*` flags write their output to file specified by the `-o` flag (#2061, #2163) -* `Approx::operator()` is now properly `const` -* Catch2's internal helper variables no longer use reserved identifiers (#578) -* `--rng-seed` now accepts string `"random-device"` to generate random seed using `std::random_device` -* Catch2 now supports test sharding (#2257) - * You can ask for the tests to be split into N groups and only run one of them. - * This greatly simplifies parallelization of tests in a binary through external runner. -* The embedded CLI parser now supports repeatedly callable lambdas - * A lambda-based option parser can opt into being repeatedly specifiable. -* Added `STATIC_CHECK` macro, similar to `STATIC_REQUIRE` (#2318) - * When deferred tu runtime, it behaves like `CHECK`, and not like `REQUIRE`. -* You can have multiple tests with the same name, as long as other parts of the test identity differ (#1915, #1999, #2175) - * Test identity includes test's name, test's tags and and test's class name if applicable. -* Added new warning, `UnmatchedTestSpec`, to error on test specs with no matching tests -* The `-w`, `--warn` warning flags can now be provided multiple times to enable multiple warnings -* The case-insensitive handling of tags is now more reliable and takes up less memory -* Test case and assertion counting can no longer reasonably overflow on 32 bit systems - * The count is now kept in `uint64_t` on all platforms, instead of using `size_t` type. -* The `-o`, `--out` output destination specifiers recognize `-` as stdout - * You have to provide it as `--out=-` to avoid CLI error about missing option - * The new reporter specification also recognizes `-` as stdout -* Multiple reporters can now run at the same time and write to different files (#1712, #2183) - * To support this, the `-r`, `--reporter` flag now also accepts optional output destination - * For full overview of the semantics of using multiple reporters, look into the reporter documentation - * To enable the new syntax, reporter names can no longer contain `::`. -* Console colour support has been rewritten and significantly improved - * The colour implementation based on ANSI colour codes is always available - * Colour implementations respect their associated stream - * previously e.g. Win32 impl would change console colour even if Catch2 was writing to a file - * The colour API is resilient against changing evaluation order of expressions - * The associated CLI flag and compile-time configuration options have changed - * For details see the docs for command-line and compile-time Catch2 configuration -* Added a support for Bazel integration with `XML_OUTPUT_FILE` env var (#2399) - * This has to be enabled during compilation. -* Added `--skip-benchmarks` flag to run tests without any `BENCHMARK`s (#2392, #2408) -* Added option to list all listeners in the binary via `--list-listeners` - - -### Fixes -* The `INFO` macro no longer contains superfluous semicolon (#1456) -* The `--list*` family of command line flags now return 0 on success (#1410, #1146) -* Various ways of failing a benchmark are now counted and reporter properly -* The ULP matcher now handles comparing numbers with different signs properly (#2152) -* Universal ADL-found operators should no longer break decomposition (#2121) -* Reporter selection is properly case-insensitive - * Previously it forced lower cased name, which would fail for reporters with upper case characters in name -* The cumulative reporter base stores benchmark results alongside assertion results -* Catch2's SE handling should no longer interferes with ASan on Windows (#2334) -* Fixed Windows console colour handling for tests that redirect stdout (#2345) -* Fixed issue with the `random` generators returning the same value over and over again - - -### Other changes -* `CATCH_CONFIG_DISABLE_MATCHERS` no longer exists. - * If you do not want to use Matchers in a TU, do not include their header. -* `CATCH_CONFIG_ENABLE_CHRONO_STRINGMAKER` no longer exists. - * `StringMaker` specializations for `` are always provided -* Catch2's CMake now provides 2 targets, `Catch2` and `Catch2WithMain`. - * `Catch2` is the statically compiled implementation by itself - * `Catch2WithMain` also links in the default main -* Catch2's pkg-config integration also provides 2 packages - * `catch2` is the statically compiled implementation by itself - * `catch2-with-main` also links in the default main -* Passing invalid test specifications passed to Catch2 are now reported before tests are run, and are a hard error. -* Running 0 tests (e.g. due to empty binary, or test spec not matching anything) returns non-0 exit code - * Flag `--allow-running-no-tests` overrides this behaviour. - * `NoTests` warning has been removed because it is fully subsumed by this change. -* Catch2's compile-time configuration options (`CATCH_CONFIG_FOO`) can be set through CMake options of the same name - * They use the same semantics as C++ defines, including the `CATCH_CONFIG_NO_FOO` overrides, - * `-DCATCH_CONFIG_DEFAULT_REPORTER=compact` changes default reporter to "compact" - * `-DCATCH_CONFIG_NO_ANDROID_LOGWRITE=ON` forces android logwrite to off - * `-DCATCH_CONFIG_ANDROID_LOGWRITE=OFF` does nothing (the define will not exist) - - - -## 2.13.7 - -### Fixes -* Added missing `` include in benchmarking. (#2231) -* Fixed noexcept build with benchmarking enabled (#2235) -* Fixed build for compilers with C++17 support but without C++17 library support (#2195) -* JUnit only uses 3 decimal places when reporting durations (#2221) -* `!mayfail` tagged tests are now marked as `skipped` in JUnit reporter output (#2116) - - -## 2.13.6 - -### Fixes -* Disabling all signal handlers no longer breaks compilation (#2212, #2213) - -### Miscellaneous -* `catch_discover_tests` should handle escaped semicolon (`;`) better (#2214, #2215) - - -## 2.13.5 - -### Improvements -* Detection of MAC and IPHONE platforms has been improved (#2140, #2157) -* Added workaround for bug in XLC 16.1.0.1 (#2155) -* Add detection for LCC when it is masquerading as GCC (#2199) -* Modified posix signal handling so it supports newer libcs (#2178) - * `MINSIGSTKSZ` was no longer usable in constexpr context. - -### Fixes -* Fixed compilation of benchmarking when `min` and `max` macros are defined (#2159) - * Including `windows.h` without `NOMINMAX` remains a really bad idea, don't do it - -### Miscellaneous -* The check whether Catch2 is being built as a subproject is now more reliable (#2202, #2204) - * The problem was that if the variable name used internally was defined the project including Catch2 as subproject, it would not be properly overwritten for Catch2's CMake. - - -## 2.13.4 - -### Improvements -* Improved the hashing algorithm used for shuffling test cases (#2070) - * `TEST_CASE`s that differ only in the last character should be properly shuffled - * Note that this means that v2.13.4 gives you a different order of test cases than 2.13.3, even given the same seed. - -### Miscellaneous -* Deprecated `ParseAndAddCatchTests` CMake integration (#2092) - * It is impossible to implement it properly for all the different test case variants Catch2 provides, and there are better options provided. - * Use `catch_discover_tests` instead, which uses runtime information about available tests. -* Fixed bug in `catch_discover_tests` that would cause it to fail when used in specific project structures (#2119) -* Added Bazel build file -* Added an experimental static library target to CMake - - -## 2.13.3 - -### Fixes -* Fixed possible infinite loop when combining generators with section filter (`-c` option) (#2025) - -### Miscellaneous -* Fixed `ParseAndAddCatchTests` not finding `TEST_CASE`s without tags (#2055, #2056) -* `ParseAndAddCatchTests` supports `CMP0110` policy for changing behaviour of `add_test` (#2057) - * This was the shortlived change in CMake 3.18.0 that temporarily broke `ParseAndAddCatchTests` - - -## 2.13.2 - -### Improvements -* Implemented workaround for AppleClang shadowing bug (#2030) -* Implemented workaround for NVCC ICE (#2005, #2027) - -### Fixes -* Fixed detection of `std::uncaught_exceptions` support under non-msvc platforms (#2021) -* Fixed the experimental stdout/stderr capture under Windows (#2013) - -### Miscellaneous -* `catch_discover_tests` has been improved significantly (#2023, #2039) - * You can now specify which reporter should be used - * You can now modify where the output will be written - * `WORKING_DIRECTORY` setting is respected -* `ParseAndAddCatchTests` now supports `TEMPLATE_TEST_CASE` macros (#2031) -* Various documentation fixes and improvements (#2022, #2028, #2034) - - -## 2.13.1 - -### Improvements -* `ParseAndAddCatchTests` handles CMake v3.18.0 correctly (#1984) -* Improved autodetection of `std::byte` (#1992) -* Simplified implementation of templated test cases (#2007) - * This should have a tiny positive effect on its compilation throughput - -### Fixes -* Automatic stringification of ranges handles sentinel ranges properly (#2004) - - -## 2.13.0 - -### Improvements -* `GENERATE` can now follow a `SECTION` at the same level of nesting (#1938) - * The `SECTION`(s) before the `GENERATE` will not be run multiple times, the following ones will. -* Added `-D`/`--min-duration` command line flag (#1910) - * If a test takes longer to finish than the provided value, its name and duration will be printed. - * This flag is overriden by setting `-d`/`--duration`. - -### Fixes -* `TAPReporter` no longer skips successful assertions (#1983) - - -## 2.12.4 - -### Improvements -* Added support for MacOS on ARM (#1971) - - -## 2.12.3 - -### Fixes -* `GENERATE` nested in a for loop no longer creates multiple generators (#1913) -* Fixed copy paste error breaking `TEMPLATE_TEST_CASE_SIG` for 6 or more arguments (#1954) -* Fixed potential UB when handling non-ASCII characters in CLI args (#1943) - -### Improvements -* There can be multiple calls to `GENERATE` on a single line -* Improved `fno-except` support for platforms that do not provide shims for exception-related std functions (#1950) - * E.g. the Green Hills C++ compiler -* XmlReporter now also reports test-case-level statistics (#1958) - * This is done via a new element, `OverallResultsCases` - -### Miscellaneous -* Added `.clang-format` file to the repo (#1182, #1920) -* Rewrote contributing docs - * They should explain the different levels of testing and so on much better - - -## 2.12.2 - -### Fixes -* Fixed compilation failure if `is_range` ADL found deleted function (#1929) -* Fixed potential UB in `CAPTURE` if the expression contained non-ASCII characters (#1925) - -### Improvements -* `std::result_of` is not used if `std::invoke_result` is available (#1934) -* JUnit reporter writes out `status` attribute for tests (#1899) -* Suppresed clang-tidy's `hicpp-vararg` warning (#1921) - * Catch2 was already suppressing the `cppcoreguidelines-pro-type-vararg` alias of the warning - - -## 2.12.1 - -### Fixes -* Vector matchers now support initializer list literals better - -### Improvements -* Added support for `^` (bitwise xor) to `CHECK` and `REQUIRE` - - - -## 2.12.0 - -### Improvements -* Running tests in random order (`--order rand`) has been reworked significantly (#1908) - * Given same seed, all platforms now produce the same order - * Given same seed, the relative order of tests does not change if you select only a subset of them -* Vector matchers support custom allocators (#1909) -* `|` and `&` (bitwise or and bitwise and) are now supported in `CHECK` and `REQUIRE` - * The resulting type must be convertible to `bool` - -### Fixes -* Fixed computation of benchmarking column widths in ConsoleReporter (#1885, #1886) -* Suppressed clang-tidy's `cppcoreguidelines-pro-type-vararg` in assertions (#1901) - * It was a false positive trigered by the new warning support workaround -* Fixed bug in test specification parser handling of OR'd patterns using escaping (#1905) - -### Miscellaneous -* Worked around IBM XL's codegen bug (#1907) - * It would emit code for _destructors_ of temporaries in an unevaluated context -* Improved detection of stdlib's support for `std::uncaught_exceptions` (#1911) - - - -## 2.11.3 - -### Fixes -* Fixed compilation error caused by lambdas in assertions under MSVC - - -## 2.11.2 - -### Improvements -* GCC and Clang now issue warnings for suspicious code in assertions (#1880) - * E.g. `REQUIRE( int != unsigned int )` will now issue mixed signedness comparison warning - * This has always worked on MSVC, but it now also works for GCC and current Clang versions -* Colorization of "Test filters" output should be more robust now -* `--wait-for-keypress` now also accepts `never` as an option (#1866) -* Reporters no longer round-off nanoseconds when reporting benchmarking results (#1876) -* Catch2's debug break now supports iOS while using Thumb instruction set (#1862) -* It is now possible to customize benchmark's warm-up time when running the test binary (#1844) - * `--benchmark-warmup-time {ms}` -* User can now specify how Catch2 should break into debugger (#1846) - -### Fixes -* Fixes missing `` include in benchmarking (#1831) -* Fixed missing `` include in benchmarking (#1874) -* Hidden test cases are now also tagged with `[!hide]` as per documentation (#1847) -* Detection of whether libc provides `std::nextafter` has been improved (#1854) -* Detection of `wmain` no longer incorrectly looks for `WIN32` macro (#1849) - * Now it just detects Windows platform -* Composing already-composed matchers no longer modifies the partially-composed matcher expression - * This bug has been present for the last ~2 years and nobody reported it - - - -## 2.11.1 - -### Improvements -* Breaking into debugger is supported on iOS (#1817) -* `google-build-using-namespace` clang-tidy warning is suppressed (#1799) - -### Fixes -* Clang on Windows is no longer assumed to implement MSVC's traditional preprocessor (#1806) -* `ObjectStorage` now behaves properly in `const` contexts (#1820) -* `GENERATE_COPY(a, b)` now compiles properly (#1809, #1815) -* Some more cleanups in the benchmarking support - - - -## 2.11.0 - -### Improvements -* JUnit reporter output now contains more details in case of failure (#1347, #1719) -* Added SonarQube Test Data reporter (#1738) - * It is in a separate header, just like the TAP, Automake, and TeamCity reporters -* `range` generator now allows floating point numbers (#1776) -* Reworked part of internals to increase throughput - - -### Fixes -* The single header version should contain full benchmarking support (#1800) -* `[.foo]` is now properly parsed as `[.][foo]` when used on the command line (#1798) -* Fixed compilation of benchmarking on platforms where `steady_clock::period` is not `std::nano` (#1794) - - - -## 2.10.2 - -### Improvements -* Catch2 will now compile on platform where `INFINITY` is double (#1782) - - -### Fixes -* Warning suppressed during listener registration will no longer leak - - - -## 2.10.1 - -### Improvements -* Catch2 now guards itself against `min` and `max` macros from `windows.h` (#1772) -* Templated tests will now compile with ICC (#1748) -* `WithinULP` matcher now uses scientific notation for stringification (#1760) - - -### Fixes -* Templated tests no longer trigger `-Wunused-templates` (#1762) -* Suppressed clang-analyzer false positive in context getter (#1230, #1735) - - -### Miscellaneous -* CMake no longer prohibits in-tree build when Catch2 is used as a subproject (#1773, #1774) - - - -## 2.10.0 - -### Fixes -* `TEMPLATE_LIST_TEST_CASE` now properly handles non-copyable and non-movable types (#1729) -* Fixed compilation error on Solaris caused by a system header defining macro `TT` (#1722, #1723) -* `REGISTER_ENUM` will now fail at compilation time if the registered enum is too large -* Removed use of `std::is_same_v` in C++17 mode (#1757) -* Fixed parsing of escaped special characters when reading test specs from a file (#1767, #1769) - - -### Improvements -* Trailing and leading whitespace in test/section specs are now ignored. -* Writing to Android debug log now uses `__android_log_write` instead of `__android_log_print` -* Android logging support can now be turned on/off at compile time (#1743) - * The toggle is `CATCH_CONFIG_ANDROID_LOGWRITE` -* Added a generator that returns elements of a range - * Use via `from_range(from, to)` or `from_range(container)` -* Added support for CRTs that do not provide `std::nextafter` (#1739) - * They must still provide global `nextafter{f,l,}` - * Enabled via `CATCH_CONFIG_GLOBAL_NEXTAFTER` -* Special cased `Approx(inf)` not to match non-infinite values - * Very strictly speaking this might be a breaking change, but it should match user expectations better -* The output of benchmarking through the Console reporter when `--benchmark-no-analysis` is set is now much simpler (#1768) -* Added a matcher that can be used for checking an exceptions message (#1649, #1728) - * The matcher helper function is called `Message` - * The exception must publicly derive from `std::exception` - * The matching is done exactly, including case and whitespace -* Added a matcher that can be used for checking relative equality of floating point numbers (#1746) - * Unlike `Approx`, it considers both sides when determining the allowed margin - * Special cases `NaN` and `INFINITY` to match user expectations - * The matcher helper function is called `WithinRel` -* The ULP matcher now allows for any possible distance between the two numbers -* The random number generators now use Catch-global instance of RNG (#1734, #1736) - * This means that nested random number generators actually generate different numbers - - -### Miscellaneous -* In-repo PNGs have been optimized to lower overhead of using Catch2 via git clone -* Catch2 now uses its own implementation of the URBG concept - * In the future we also plan to use our own implementation of the distributions from `` to provide cross-platform repeatability of random results - - - -## 2.9.2 - -### Fixes -* `ChunkGenerator` can now be used with chunks of size 0 (#1671) -* Nested subsections are now run properly when specific section is run via the `-c` argument (#1670, #1673) -* Catch2 now consistently uses `_WIN32` to detect Windows platform (#1676) -* `TEMPLATE_LIST_TEST_CASE` now support non-default constructible type lists (#1697) -* Fixed a crash in the XMLReporter when a benchmark throws exception during warmup (#1706) -* Fixed a possible infinite loop in CompactReporter (#1715) -* Fixed `-w NoTests` returning 0 even when no tests were matched (#1449, #1683, #1684) -* Fixed matcher compilation under Obj-C++ (#1661) - -### Improvements -* `RepeatGenerator` and `FixedValuesGenerator` now fail to compile when used with `bool` (#1692) - * Previously they would fail at runtime. -* Catch2 now supports Android's debug logging for its debug output (#1710) -* Catch2 now detects and configures itself for the RTX platform (#1693) - * You still need to pass `--benchmark-no-analysis` if you are using benchmarking under RTX -* Removed a "storage class is not first" warning when compiling Catch2 with PGI compiler (#1717) - -### Miscellaneous -* Documentation now contains indication when a specific feature was introduced (#1695) - * These start with Catch2 v2.3.0, (a bit over a year ago). - * `docs/contributing.md` has been updated to provide contributors guidance on how to add these to newly written documentation -* Various other documentation improvements - * ToC fixes - * Documented `--order` and `--rng-seed` command line options - * Benchmarking documentation now clearly states that it requires opt-in - * Documented `CATCH_CONFIG_CPP17_OPTIONAL` and `CATCH_CONFIG_CPP17_BYTE` macros - * Properly documented built-in vector matchers - * Improved `*_THROWS_MATCHES` documentation a bit -* CMake config file is now arch-independent even if `CMAKE_SIZEOF_VOID_P` is in CMake cache (#1660) -* `CatchAddTests` now properly escapes `[` and `]` in test names (#1634, #1698) -* Reverted `CatchAddTests` adding tags as CTest labels (#1658) - * The script broke when test names were too long - * Overwriting `LABELS` caused trouble for users who set them manually - * CMake does not let users append to `LABELS` if the test name has spaces - - -## 2.9.1 - -### Fixes -* Fix benchmarking compilation failure in files without `CATCH_CONFIG_EXTERNAL_INTERFACES` (or implementation) - - -## 2.9.0 - -### Improvements -* The experimental benchmarking support has been replaced by integrating Nonius code (#1616) - * This provides a much more featurefull micro-benchmarking support. - * Due to the compilation cost, it is disabled by default. See the documentation for details. - * As far as backwards compatibility is concerned, this feature is still considered experimental in that we might change the interface based on user feedback. -* `WithinULP` matcher now shows the acceptable range (#1581) -* Template test cases now support type lists (#1627) - - -## 2.8.0 - -### Improvements -* Templated test cases no longer check whether the provided types are unique (#1628) - * This allows you to e.g. test over `uint32_t`, `uint64_t`, and `size_t` without compilation failing -* The precision of floating point stringification can be modified by user (#1612, #1614) -* We now provide `REGISTER_ENUM` convenience macro for generating `StringMaker` specializations for enums - * See the "String conversion" documentation for details -* Added new set of macros for template test cases that enables the use of NTTPs (#1531, #1609) - * See "Test cases and sections" documentation for details - -### Fixes -* `UNSCOPED_INFO` macro now has a prefixed/disabled/prefixed+disabled versions (#1611) -* Reporting errors at startup should no longer cause a segfault under certain circumstances (#1626) - - -### Miscellaneous -* CMake will now prevent you from attempting in-tree build (#1636, #1638) - * Previously it would break with an obscure error message during the build step - - -## 2.7.2 - -### Improvements -* Added an approximate vector matcher (#1499) - -### Fixes -* Filters will no longer be shown if there were none -* Fixed compilation error when using Homebrew GCC on OS X (#1588, #1589) -* Fixed the console reporter not showing messages that start with a newline (#1455, #1470) -* Modified JUnit reporter's output so that rng seed and filters are reported according to the JUnit schema (#1598) -* Fixed some obscure warnings and static analysis passes - -### Miscellaneous -* Various improvements to `ParseAndAddCatchTests` (#1559, #1601) - * When a target is parsed, it receives `ParseAndAddCatchTests_TESTS` property which summarizes found tests - * Fixed problem with tests not being found if the `OptionalCatchTestLauncher` variables is used - * Including the script will no longer forcefully modify `CMAKE_MINIMUM_REQUIRED_VERSION` - * CMake object libraries are ignored when parsing to avoid needless warnings -* `CatchAddTests` now adds test's tags to their CTest labels (#1600) -* Added basic CPack support to our build - -## 2.7.1 - -### Improvements -* Reporters now print out the filters applied to test cases (#1550, #1585) -* Added `GENERATE_COPY` and `GENERATE_REF` macros that can use variables inside the generator expression - * Because of the significant danger of lifetime issues, the default `GENERATE` macro still does not allow variables -* The `map` generator helper now deduces the mapped return type (#1576) - -### Fixes -* Fixed ObjC++ compilation (#1571) -* Fixed test tag parsing so that `[.foo]` is now parsed as `[.][foo]`. -* Suppressed warning caused by the Windows headers defining SE codes in different manners (#1575) - -## 2.7.0 - -### Improvements -* `TEMPLATE_PRODUCT_TEST_CASE` now uses the resulting type in the name, instead of the serial number (#1544) -* Catch2's single header is now strictly ASCII (#1542) -* Added generator for random integral/floating point types - * The types are inferred within the `random` helper -* Added back RangeGenerator (#1526) - * RangeGenerator returns elements within a certain range -* Added ChunkGenerator generic transform (#1538) - * A ChunkGenerator returns the elements from different generator in chunks of n elements -* Added `UNSCOPED_INFO` (#415, #983, #1522) - * This is a variant of `INFO` that lives until next assertion/end of the test case. - - -### Fixes -* All calls to C stdlib functions are now `std::` qualified (#1541) - * Code brought in from Clara was also updated. -* Running tests will no longer open the specified output file twice (#1545) - * This would cause trouble when the file was not a file, but rather a named pipe - * Fixes the CLion/Resharper integration with Catch -* Fixed `-Wunreachable-code` occurring with (old) ccache+cmake+clang combination (#1540) -* Fixed `-Wdefaulted-function-deleted` warning with Clang 8 (#1537) -* Catch2's type traits and helpers are now properly namespaced inside `Catch::` (#1548) -* Fixed std{out,err} redirection for failing test (#1514, #1525) - * Somehow, this bug has been present for well over a year before it was reported - - -### Contrib -* `ParseAndAddCatchTests` now properly escapes commas in the test name - - - -## 2.6.1 - -### Improvements -* The JUnit reporter now also reports random seed (#1520, #1521) - -### Fixes -* The TAP reporter now formats comments with test name properly (#1529) -* `CATCH_REQUIRE_THROWS`'s internals were unified with `REQUIRE_THROWS` (#1536) - * This fixes a potential `-Wunused-value` warning when used -* Fixed a potential segfault when using any of the `--list-*` options (#1533, #1534) - - -## 2.6.0 - -**With this release the data generator feature is now fully supported.** - - -### Improvements -* Added `TEMPLATE_PRODUCT_TEST_CASE` (#1454, #1468) - * This allows you to easily test various type combinations, see documentation for details -* The error message for `&&` and `||` inside assertions has been improved (#1273, #1480) -* The error message for chained comparisons inside assertions has been improved (#1481) -* Added `StringMaker` specialization for `std::optional` (#1510) -* The generator interface has been redone once again (#1516) - * It is no longer considered experimental and is fully supported - * The new interface supports "Input" generators - * The generator documentation has been fully updated - * We also added 2 generator examples - - -### Fixes -* Fixed `-Wredundant-move` on newer Clang (#1474) -* Removed unreachable mentions `std::current_exception`, `std::rethrow_exception` in no-exceptions mode (#1462) - * This should fix compilation with IAR -* Fixed missing `` include (#1494) -* Fixed various static analysis warnings - * Unrestored stream state in `XmlWriter` (#1489) - * Potential division by zero in `estimateClockResolution` (#1490) - * Uninitialized member in `RunContext` (#1491) - * `SourceLineInfo` move ops are now marked `noexcept` - * `CATCH_BREAK_INTO_DEBUGGER` is now always a function -* Fix double run of a test case if user asks for a specific section (#1394, #1492) -* ANSI colour code output now respects `-o` flag and writes to the file as well (#1502) -* Fixed detection of `std::variant` support for compilers other than Clang (#1511) - - -### Contrib -* `ParseAndAddCatchTests` has learned how to use `DISABLED` CTest property (#1452) -* `ParseAndAddCatchTests` now works when there is a whitspace before the test name (#1493) - - -### Miscellaneous -* We added new issue templates for reporting issues on GitHub -* `contributing.md` has been updated to reflect the current test status (#1484) - - - -## 2.5.0 - -### Improvements -* Added support for templated tests via `TEMPLATE_TEST_CASE` (#1437) - - -### Fixes -* Fixed compilation of `PredicateMatcher` by removing partial specialization of `MatcherMethod` -* Listeners now implicitly support any verbosity (#1426) -* Fixed compilation with Embarcadero builder by introducing `Catch::isnan` polyfill (#1438) -* Fixed `CAPTURE` asserting for non-trivial captures (#1436, #1448) - - -### Miscellaneous -* We should now be providing first party Conan support via https://bintray.com/catchorg/Catch2 (#1443) -* Added new section "deprecations and planned changes" to the documentation - * It contains summary of what is deprecated and might change with next major version -* From this release forward, the released headers should be pgp signed (#430) - * KeyID `E29C 46F3 B8A7 5028 6079 3B7D ECC9 C20E 314B 2360` - * or https://codingnest.com/files/horenmar-publickey.asc - - -## 2.4.2 - -### Improvements -* XmlReporter now also outputs the RNG seed that was used in a run (#1404) -* `Catch::Session::applyCommandLine` now also accepts `wchar_t` arguments. - * However, Catch2 still does not support unicode. -* Added `STATIC_REQUIRE` macro (#1356, #1362) -* Catch2's singleton's are now cleaned up even if tests are run (#1411) - * This is mostly useful as a FP prevention for users who define their own main. -* Specifying an invalid reporter via `-r` is now reported sooner (#1351, #1422) - - -### Fixes -* Stringification no longer assumes that `char` is signed (#1399, #1407) - * This caused a `Wtautological-compare` warning. -* SFINAE for `operator<<` no longer sees different overload set than the actual insertion (#1403) - - -### Contrib -* `catch_discover_tests` correctly adds tests with comma in name (#1327, #1409) -* Added a new customization point in how the tests are launched to `catch_discover_tests` - - -## 2.4.1 - -### Improvements -* Added a StringMaker for `std::(w)string_view` (#1375, #1376) -* Added a StringMaker for `std::variant` (#1380) - * This one is disabled by default to avoid increased compile-time drag -* Added detection for cygwin environment without `std::to_string` (#1396, #1397) - -### Fixes -* `UnorderedEqualsMatcher` will no longer accept erroneously accept -vectors that share suffix, but are not permutation of the desired vector -* Abort after (`-x N`) can no longer be overshot by nested `REQUIRES` and -subsequently ignored (#1391, #1392) - - -## 2.4.0 - -**This release brings two new experimental features, generator support -and a `-fno-exceptions` support. Being experimental means that they -will not be subject to the usual stability guarantees provided by semver.** - -### Improvements -* Various small runtime performance improvements -* `CAPTURE` macro is now variadic -* Added `AND_GIVEN` macro (#1360) -* Added experimental support for data generators - * See [their documentation](generators.md) for details -* Added support for compiling and running Catch without exceptions - * Doing so limits the functionality somewhat - * Look [into the documentation](configuration.md#disablingexceptions) for details - -### Fixes -* Suppressed `-Wnon-virtual-dtor` warnings in Matchers (#1357) -* Suppressed `-Wunreachable-code` warnings in floating point matchers (#1350) - -### CMake -* It is now possible to override which Python is used to run Catch's tests (#1365) -* Catch now provides infrastructure for adding tests that check compile-time configuration -* Catch no longer tries to install itself when used as a subproject (#1373) -* Catch2ConfigVersion.cmake is now generated as arch-independent (#1368) - * This means that installing Catch from 32-bit machine and copying it to 64-bit one works - * This fixes conan installation of Catch - - -## 2.3.0 - -**This release changes the include paths provided by our CMake and -pkg-config integration. The proper include path for the single-header -when using one of the above is now ``. This change -also necessitated changes to paths inside the repository, so that the -single-header version is now at `single_include/catch2/catch.hpp`, rather -than `single_include/catch.hpp`.** - - - -### Fixes -* Fixed Objective-C++ build -* `-Wunused-variable` suppression no longer leaks from Catch's header under Clang -* Implementation of the experimental new output capture can now be disabled (#1335) - * This allows building Catch2 on platforms that do not provide things like `dup` or `tmpfile`. -* The JUnit and XML reporters will no longer skip over successful tests when running without `-s` (#1264, #1267, #1310) - * See improvements for more details - -### Improvements -* pkg-config and CMake integration has been rewritten - * If you use them, the new include path is `#include ` - * CMake installation now also installs scripts from `contrib/` - * For details see the [new documentation](cmake-integration.md#top) -* Reporters now have a new customization point, `ReporterPreferences::shouldReportAllAssertions` - * When this is set to `false` and the tests are run without `-s`, passing assertions are not sent to the reporter. - * Defaults to `false`. -* Added `DYNAMIC_SECTION`, a section variant that constructs its name using stream - * This means that you can do `DYNAMIC_SECTION("For X := " << x)`. - - -## 2.2.3 - -**To fix some of the bugs, some behavior had to change in potentially breaking manner.** -**This means that even though this is a patch release, it might not be a drop-in replacement.** - -### Fixes -* Listeners are now called before reporter - * This was always documented to be the case, now it actually works that way -* Catch's commandline will no longer accept multiple reporters - * This was done because multiple reporters never worked properly and broke things in non-obvious ways - * **This has potential to be a breaking change** -* MinGW is now detected as Windows platform w/o SEH support (#1257) - * This means that Catch2 no longer tries to use POSIX signal handling when compiled with MinGW -* Fixed potential UB in parsing tags using non-ASCII characters (#1266) - * Note that Catch2 still supports only ASCII test names/tags/etc -* `TEST_CASE_METHOD` can now be used on classnames containing commas (#1245) - * You have to enclose the classname in extra set of parentheses -* Fixed insufficient alt stack size for POSIX signal handling (#1225) -* Fixed compilation error on Android due to missing `std::to_string` in C++11 mode (#1280) -* Fixed the order of user-provided `FALLBACK_STRINGIFIER` in stringification machinery (#1024) - * It was intended to be replacement for built-in fallbacks, but it was used _after_ them. - * **This has potential to be a breaking change** -* Fixed compilation error when a type has an `operator<<` with templated lhs (#1285, #1306) - -### Improvements -* Added a new, experimental, output capture (#1243) - * This capture can also redirect output written via C apis, e.g. `printf` - * To opt-in, define `CATCH_CONFIG_EXPERIMENTAL_REDIRECT` in the implementation file -* Added a new fallback stringifier for classes derived from `std::exception` - * Both `StringMaker` specialization and `operator<<` overload are given priority - -### Miscellaneous -* `contrib/` now contains dbg scripts that skip over Catch's internals (#904, #1283) - * `gdbinit` for gdb `lldbinit` for lldb -* `CatchAddTests.cmake` no longer strips whitespace from tests (#1265, #1281) -* Online documentation now describes `--use-colour` option (#1263) - - -## 2.2.2 - -### Fixes -* Fixed bug in `WithinAbs::match()` failing spuriously (#1228) -* Fixed clang-tidy diagnostic about virtual call in destructor (#1226) -* Reduced the number of GCC warnings suppression leaking out of the header (#1090, #1091) - * Only `-Wparentheses` should be leaking now -* Added upper bound on the time benchmark timer calibration is allowed to take (#1237) - * On platforms where `std::chrono::high_resolution_clock`'s resolution is low, the calibration would appear stuck -* Fixed compilation error when stringifying static arrays of `unsigned char`s (#1238) - -### Improvements -* XML encoder now hex-encodes invalid UTF-8 sequences (#1207) - * This affects xml and junit reporters - * Some invalid UTF-8 parts are left as is, e.g. surrogate pairs. This is because certain extensions of UTF-8 allow them, such as WTF-8. -* CLR objects (`T^`) can now be stringified (#1216) - * This affects code compiled as C++/CLI -* Added `PredicateMatcher`, a matcher that takes an arbitrary predicate function (#1236) - * See [documentation for details](https://github.com/catchorg/Catch2/blob/devel/docs/matchers.md) - -### Others -* Modified CMake-installed pkg-config to allow `#include `(#1239) - * The plans to standardize on `#include ` are still in effect - - -## 2.2.1 - -### Fixes -* Fixed compilation error when compiling Catch2 with `std=c++17` against libc++ (#1214) - * Clara (Catch2's CLI parsing library) used `std::optional` without including it explicitly -* Fixed Catch2 return code always being 0 (#1215) - * In the words of STL, "We feel superbad about letting this in" - - -## 2.2.0 - -### Fixes -* Hidden tests are not listed by default when listing tests (#1175) - * This makes `catch_discover_tests` CMake script work better -* Fixed regression that meant `` could potentially not be included properly (#1197) -* Fixed installing `Catch2ConfigVersion.cmake` when Catch2 is a subproject. - -### Improvements -* Added an option to warn (+ exit with error) when no tests were ran (#1158) - * Use as `-w NoTests` -* Added provisional support for Emscripten (#1114) -* [Added a way to override the fallback stringifier](https://github.com/catchorg/Catch2/blob/devel/docs/configuration.md#fallback-stringifier) (#1024) - * This allows project's own stringification machinery to be easily reused for Catch -* `Catch::Session::run()` now accepts `char const * const *`, allowing it to accept array of string literals (#1031, #1178) - * The embedded version of Clara was bumped to v1.1.3 -* Various minor performance improvements -* Added support for DJGPP DOS crosscompiler (#1206) - - -## 2.1.2 - -### Fixes -* Fixed compilation error with `-fno-rtti` (#1165) -* Fixed NoAssertion warnings -* `operator<<` is used before range-based stringification (#1172) -* Fixed `-Wpedantic` warnings (extra semicolons and binary literals) (#1173) - - -### Improvements -* Added `CATCH_VERSION_{MAJOR,MINOR,PATCH}` macros (#1131) -* Added `BrightYellow` colour for use in reporters (#979) - * It is also used by ConsoleReporter for reconstructed expressions - -### Other changes -* Catch is now exported as a CMake package and linkable target (#1170) - -## 2.1.1 - -### Improvements -* Static arrays are now properly stringified like ranges across MSVC/GCC/Clang -* Embedded newer version of Clara -- v1.1.1 - * This should fix some warnings dragged in from Clara -* MSVC's CLR exceptions are supported - - -### Fixes -* Fixed compilation when comparison operators do not return bool (#1147) -* Fixed CLR exceptions blowing up the executable during translation (#1138) - - -### Other changes -* Many CMake changes - * `NO_SELFTEST` option is deprecated, use `BUILD_TESTING` instead. - * Catch specific CMake options were prefixed with `CATCH_` for namespacing purposes - * Other changes to simplify Catch2's packaging - - - -## 2.1.0 - -### Improvements -* Various performance improvements - * On top of the performance regression fixes -* Experimental support for PCH was added (#1061) -* `CATCH_CONFIG_EXTERNAL_INTERFACES` now brings in declarations of Console, Compact, XML and JUnit reporters -* `MatcherBase` no longer has a pointless second template argument -* Reduced the number of warning suppressions that leak into user's code - * Bugs in g++ 4.x and 5.x mean that some of them have to be left in - - -### Fixes -* Fixed performance regression from Catch classic - * One of the performance improvement patches for Catch classic was not applied to Catch2 -* Fixed platform detection for iOS (#1084) -* Fixed compilation when `g++` is used together with `libc++` (#1110) -* Fixed TeamCity reporter compilation with the single header version - * To fix the underlying issue we will be versioning reporters in single_include folder per release -* The XML reporter will now report `WARN` messages even when not used with `-s` -* Fixed compilation when `VectorContains` matcher was combined using `&&` (#1092) -* Fixed test duration overflowing after 10 seconds (#1125, #1129) -* Fixed `std::uncaught_exception` deprecation warning (#1124) - - -### New features -* New Matchers - * Regex matcher for strings, `Matches`. - * Set-equal matcher for vectors, `UnorderedEquals` - * Floating point matchers, `WithinAbs` and `WithinULP`. -* Stringification now attempts to decompose all containers (#606) - * Containers are objects that respond to ADL `begin(T)` and `end(T)`. - - -### Other changes -* Reporters will now be versioned in the `single_include` folder to ensure their compatibility with the last released version - - - - -## 2.0.1 - -### Breaking changes -* Removed C++98 support -* Removed legacy reporter support -* Removed legacy generator support - * Generator support will come back later, reworked -* Removed `Catch::toString` support - * The new stringification machinery uses `Catch::StringMaker` specializations first and `operator<<` overloads second. -* Removed legacy `SCOPED_MSG` and `SCOPED_INFO` macros -* Removed `INTERNAL_CATCH_REGISTER_REPORTER` - * `CATCH_REGISTER_REPORTER` should be used to register reporters -* Removed legacy `[hide]` tag - * `[.]`, `[.foo]` and `[!hide]` are still supported -* Output into debugger is now colourized -* `*_THROWS_AS(expr, exception_type)` now unconditionally appends `const&` to the exception type. -* `CATCH_CONFIG_FAST_COMPILE` now affects the `CHECK_` family of assertions as well as `REQUIRE_` family of assertions - * This is most noticeable in `CHECK(throws())`, which would previously report failure, properly stringify the exception and continue. Now it will report failure and stop executing current section. -* Removed deprecated matcher utility functions `Not`, `AllOf` and `AnyOf`. - * They are superseded by operators `!`, `&&` and `||`, which are natural and do not have limited arity -* Removed support for non-const comparison operators - * Non-const comparison operators are an abomination that should not exist - * They were breaking support for comparing function to function pointer -* `std::pair` and `std::tuple` are no longer stringified by default - * This is done to avoid dragging in `` and `` headers in common path - * Their stringification can be enabled per-file via new configuration macros -* `Approx` is subtly different and hopefully behaves more as users would expect - * `Approx::scale` defaults to `0.0` - * `Approx::epsilon` no longer applies to the larger of the two compared values, but only to the `Approx`'s value - * `INFINITY == Approx(INFINITY)` returns true - - -### Improvements -* Reporters and Listeners can be defined in files different from the main file - * The file has to define `CATCH_CONFIG_EXTERNAL_INTERFACES` before including catch.hpp. -* Errors that happen during set up before main are now caught and properly reported once main is entered - * If you are providing your own main, you can access and use these as well. -* New assertion macros, *_THROWS_MATCHES(expr, exception_type, matcher) are provided - * As the arguments suggest, these allow you to assert that an expression throws desired type of exception and pass the exception to a matcher. -* JUnit reporter no longer has significantly different output for test cases with and without sections -* Most assertions now support expressions containing commas (ie `REQUIRE(foo() == std::vector{1, 2, 3});`) -* Catch now contains experimental micro benchmarking support - * See `projects/SelfTest/Benchmark.tests.cpp` for examples - * The support being experiment means that it can be changed without prior notice -* Catch uses new CLI parsing library (Clara) - * Users can now easily add new command line options to the final executable - * This also leads to some changes in `Catch::Session` interface -* All parts of matchers can be removed from a TU by defining `CATCH_CONFIG_DISABLE_MATCHERS` - * This can be used to somewhat speed up compilation times -* An experimental implementation of `CATCH_CONFIG_DISABLE` has been added - * Inspired by Doctest's `DOCTEST_CONFIG_DISABLE` - * Useful for implementing tests in source files - * ie for functions in anonymous namespaces - * Removes all assertions - * Prevents `TEST_CASE` registrations - * Exception translators are not registered - * Reporters are not registered - * Listeners are not registered -* Reporters/Listeners are now notified of fatal errors - * This means specific signals or structured exceptions - * The Reporter/Listener interface provides default, empty, implementation to preserve backward compatibility -* Stringification of `std::chrono::duration` and `std::chrono::time_point` is now supported - * Needs to be enabled by a per-file compile time configuration option -* Add `pkg-config` support to CMake install command - - -### Fixes -* Don't use console colour if running in XCode -* Explicit constructor in reporter base class -* Swept out `-Wweak-vtables`, `-Wexit-time-destructors`, `-Wglobal-constructors` warnings -* Compilation for Universal Windows Platform (UWP) is supported - * SEH handling and colorized output are disabled when compiling for UWP -* Implemented a workaround for `std::uncaught_exception` issues in libcxxrt - * These issues caused incorrect section traversals - * The workaround is only partial, user's test can still trigger the issue by using `throw;` to rethrow an exception -* Suppressed C4061 warning under MSVC - - -### Internal changes -* The development version now uses .cpp files instead of header files containing implementation. - * This makes partial rebuilds much faster during development -* The expression decomposition layer has been rewritten -* The evaluation layer has been rewritten -* New library (TextFlow) is used for formatting text to output - - -## Older versions - -### 1.12.x - -#### 1.12.2 -##### Fixes -* Fixed missing include - -#### 1.12.1 - -##### Fixes -* Fixed deprecation warning in `ScopedMessage::~ScopedMessage` -* All uses of `min` or `max` identifiers are now wrapped in parentheses - * This avoids problems when Windows headers define `min` and `max` macros - -#### 1.12.0 - -##### Fixes -* Fixed compilation for strict C++98 mode (ie not gnu++98) and older compilers (#1103) -* `INFO` messages are included in the `xml` reporter output even without `-s` specified. - - -### 1.11.x - -#### 1.11.0 - -##### Fixes -* The original expression in `REQUIRE_FALSE( expr )` is now reporter properly as `!( expr )` (#1051) - * Previously the parentheses were missing and `x != y` would be expanded as `!x != x` -* `Approx::Margin` is now inclusive (#952) - * Previously it was meant and documented as inclusive, but the check itself wasn't - * This means that `REQUIRE( 0.25f == Approx( 0.0f ).margin( 0.25f ) )` passes, instead of fails -* `RandomNumberGenerator::result_type` is now unsigned (#1050) - -##### Improvements -* `__JETBRAINS_IDE__` macro handling is now CLion version specific (#1017) - * When CLion 2017.3 or newer is detected, `__COUNTER__` is used instead of -* TeamCity reporter now explicitly flushes output stream after each report (#1057) - * On some platforms, output from redirected streams would show up only after the tests finished running -* `ParseAndAddCatchTests` now can add test files as dependency to CMake configuration - * This means you do not have to manually rerun CMake configuration step to detect new tests - -### 1.10.x - -#### 1.10.0 - -##### Fixes -* Evaluation layer has been rewritten (backported from Catch 2) - * The new layer is much simpler and fixes some issues (#981) -* Implemented workaround for VS 2017 raw string literal stringification bug (#995) -* Fixed interaction between `[!shouldfail]` and `[!mayfail]` tags and sections - * Previously sections with failing assertions would be marked as failed, not failed-but-ok - -##### Improvements -* Added [libidentify](https://github.com/janwilmans/LibIdentify) support -* Added "wait-for-keypress" option - -### 1.9.x - -#### 1.9.6 - -##### Improvements -* Catch's runtime overhead has been significantly decreased (#937, #939) -* Added `--list-extra-info` cli option (#934). - * It lists all tests together with extra information, ie filename, line number and description. - - - -#### 1.9.5 - -##### Fixes -* Truthy expressions are now reconstructed properly, not as booleans (#914) -* Various warnings are no longer erroneously suppressed in test files (files that include `catch.hpp`, but do not define `CATCH_CONFIG_MAIN` or `CATCH_CONFIG_RUNNER`) (#871) -* Catch no longer fails to link when main is compiled as C++, but linked against Objective-C (#855) -* Fixed incorrect gcc version detection when deciding to use `__COUNTER__` (#928) - * Previously any GCC with minor version less than 3 would be incorrectly classified as not supporting `__COUNTER__`. -* Suppressed C4996 warning caused by upcoming updated to MSVC 2017, marking `std::uncaught_exception` as deprecated. (#927) - -##### Improvements -* CMake integration script now incorporates debug messages and registers tests in an improved way (#911) -* Various documentation improvements - - - -#### 1.9.4 - -##### Fixes -* `CATCH_FAIL` macro no longer causes compilation error without variadic macro support -* `INFO` messages are no longer cleared after being reported once - -##### Improvements and minor changes -* Catch now uses `wmain` when compiled under Windows and `UNICODE` is defined. - * Note that Catch still officially supports only ASCII - -#### 1.9.3 - -##### Fixes -* Completed the fix for (lack of) uint64_t in earlier Visual Studios - -#### 1.9.2 - -##### Improvements and minor changes -* All of `Approx`'s member functions now accept strong typedefs in C++11 mode (#888) - * Previously `Approx::scale`, `Approx::epsilon`, `Approx::margin` and `Approx::operator()` didn't. - - -##### Fixes -* POSIX signals are now disabled by default under QNX (#889) - * QNX does not support current enough (2001) POSIX specification -* JUnit no longer counts exceptions as failures if given test case is marked as ok to fail. -* `Catch::Option` should now have its storage properly aligned. -* Catch no longer attempts to define `uint64_t` on windows (#862) - * This was causing trouble when compiled under Cygwin - -##### Other -* Catch is now compiled under MSVC 2017 using `std:c++latest` (C++17 mode) in CI -* We now provide cmake script that autoregisters Catch tests into ctest. - * See `contrib` folder. - - -#### 1.9.1 - -##### Fixes -* Unexpected exceptions are no longer ignored by default (#885, #887) - - -#### 1.9.0 - - -##### Improvements and minor changes -* Catch no longer attempts to ensure the exception type passed by user in `REQUIRE_THROWS_AS` is a constant reference. - * It was causing trouble when `REQUIRE_THROWS_AS` was used inside templated functions - * This actually reverts changes made in v1.7.2 -* Catch's `Version` struct should no longer be double freed when multiple instances of Catch tests are loaded into single program (#858) - * It is now a static variable in an inline function instead of being an `extern`ed struct. -* Attempt to register invalid tag or tag alias now throws instead of calling `exit()`. - * Because this happen before entering main, it still aborts execution - * Further improvements to this are coming -* `CATCH_CONFIG_FAST_COMPILE` now speeds-up compilation of `REQUIRE*` assertions by further ~15%. - * The trade-off is disabling translation of unexpected exceptions into text. -* When Catch is compiled using C++11, `Approx` is now constructible with anything that can be explicitly converted to `double`. -* Captured messages are now printed on unexpected exceptions - -##### Fixes: -* Clang's `-Wexit-time-destructors` should be suppressed for Catch's internals -* GCC's `-Wparentheses` is now suppressed for all TU's that include `catch.hpp`. - * This is functionally a revert of changes made in 1.8.0, where we tried using `_Pragma` based suppression. This should have kept the suppression local to Catch's assertions, but bugs in GCC's handling of `_Pragma`s in C++ mode meant that it did not always work. -* You can now tell Catch to use C++11-based check when checking whether a type can be streamed to output. - * This fixes cases when an unstreamable type has streamable private base (#877) - * [Details can be found in documentation](configuration.md#catch_config_cpp11_stream_insertable_check) - - -##### Other notes: -* We have added VS 2017 to our CI -* Work on Catch 2 should start soon - - - -### 1.8.x - -#### 1.8.2 - - -##### Improvements and minor changes -* TAP reporter now behaves as if `-s` was always set - * This should be more consistent with the protocol desired behaviour. -* Compact reporter now obeys `-d yes` argument (#780) - * The format is "XXX.123 s: " (3 decimal places are always present). - * Before it did not report the durations at all. -* XML reporter now behaves the same way as Console reporter in regards to `INFO` - * This means it reports `INFO` messages on success, if output on success (`-s`) is enabled. - * Previously it only reported `INFO` messages on failure. -* `CAPTURE(expr)` now stringifies `expr` in the same way assertion macros do (#639) -* Listeners are now finally [documented](event-listeners.md#top). - * Listeners provide a way to hook into events generated by running your tests, including start and end of run, every test case, every section and every assertion. - - -##### Fixes: -* Catch no longer attempts to reconstruct expression that led to a fatal error (#810) - * This fixes possible signal/SEH loop when processing expressions, where the signal was triggered by expression decomposition. -* Fixed (C4265) missing virtual destructor warning in Matchers (#844) -* `std::string`s are now taken by `const&` everywhere (#842). - * Previously some places were taking them by-value. -* Catch should no longer change errno (#835). - * This was caused by libstdc++ bug that we now work around. -* Catch now provides `FAIL_CHECK( ... )` macro (#765). - * Same as `FAIL( ... )`, but does not abort the test. -* Functions like `fabs`, `tolower`, `memset`, `isalnum` are now used with `std::` qualification (#543). -* Clara no longer assumes first argument (binary name) is always present (#729) - * If it is missing, empty string is used as default. -* Clara no longer reads 1 character past argument string (#830) -* Regression in Objective-C bindings (Matchers) fixed (#854) - - -##### Other notes: -* We have added VS 2013 and 2015 to our CI -* Catch Classic (1.x.x) now contains its own, forked, version of Clara (the argument parser). - - - -#### 1.8.1 - -##### Fixes - -Cygwin issue with `gettimeofday` - `#define` was not early enough - -#### 1.8.0 - -##### New features/ minor changes - -* Matchers have new, simpler (and documented) interface. - * Catch provides string and vector matchers. - * For details see [Matchers documentation](matchers.md#top). -* Changed console reporter test duration reporting format (#322) - * Old format: `Some simple comparisons between doubles completed in 0.000123s` - * New format: `xxx.123s: Some simple comparisons between doubles` _(There will always be exactly 3 decimal places)_ -* Added opt-in leak detection under MSVC + Windows (#439) - * Enable it by compiling Catch's main with `CATCH_CONFIG_WINDOWS_CRTDBG` -* Introduced new compile-time flag, `CATCH_CONFIG_FAST_COMPILE`, trading features for compilation speed. - * Moves debug breaks out of tests and into implementation, speeding up test compilation time (~10% on linux). - * _More changes are coming_ -* Added [TAP (Test Anything Protocol)](https://testanything.org/) and [Automake](https://www.gnu.org/software/automake/manual/html_node/Log-files-generation-and-test-results-recording.html#Log-files-generation-and-test-results-recording) reporters. - * These are not present in the default single-include header and need to be downloaded from GitHub separately. - * For details see [documentation about integrating with build systems](build-systems.md#top). -* XML reporter now reports filename as part of the `Section` and `TestCase` tags. -* `Approx` now supports an optional margin of absolute error - * It has also received [new documentation](assertions.md#top). - -##### Fixes -* Silenced C4312 ("conversion from int to 'ClassName *") warnings in the evaluate layer. -* Fixed C4512 ("assignment operator could not be generated") warnings under VS2013. -* Cygwin compatibility fixes - * Signal handling is no longer compiled by default. - * Usage of `gettimeofday` inside Catch should no longer cause compilation errors. -* Improved `-Wparentheses` suppression for gcc (#674) - * When compiled with gcc 4.8 or newer, the suppression is localized to assertions only - * Otherwise it is suppressed for the whole TU -* Fixed test spec parser issue (with escapes in multiple names) - -##### Other -* Various documentation fixes and improvements - - -### 1.7.x - -#### 1.7.2 - -##### Fixes and minor improvements -Xml: - -(technically the first two are breaking changes but are also fixes and arguably break few if any people) -* C-escape control characters instead of XML encoding them (which requires XML 1.1) -* Revert XML output to XML 1.0 -* Can provide stylesheet references by extending the XML reporter -* Added description and tags attributes to XML Reporter -* Tags are closed and the stream flushed more eagerly to avoid stdout interpolation - - -Other: -* `REQUIRE_THROWS_AS` now catches exception by `const&` and reports expected type -* In `SECTION`s the file/ line is now of the `SECTION`. not the `TEST_CASE` -* Added std:: qualification to some functions from C stdlib -* Removed use of RTTI (`dynamic_cast`) that had crept back in -* Silenced a few more warnings in different circumstances -* Travis improvements - -#### 1.7.1 - -##### Fixes: -* Fixed inconsistency in defining `NOMINMAX` and `WIN32_LEAN_AND_MEAN` inside `catch.hpp`. -* Fixed SEH-related compilation error under older MinGW compilers, by making Windows SEH handling opt-in for compilers other than MSVC. - * For specifics, look into the [documentation](configuration.md#top). -* Fixed compilation error under MinGW caused by improper compiler detection. -* Fixed XML reporter sometimes leaving an empty output file when a test ends with signal/structured exception. -* Fixed XML reporter not reporting captured stdout/stderr. -* Fixed possible infinite recursion in Windows SEH. -* Fixed possible compilation error caused by Catch's operator overloads being ambiguous in regards to user-defined templated operators. - -#### 1.7.0 - -##### Features/ Changes: -* Catch now runs significantly faster for passing tests - * Microbenchmark focused on Catch's overhead went from ~3.4s to ~0.7s. - * Real world test using [JSON for Modern C++](https://github.com/nlohmann/json)'s test suite went from ~6m 25s to ~4m 14s. -* Catch can now run specific sections within test cases. - * For now the support is only basic (no wildcards or tags), for details see the [documentation](command-line.md#top). -* Catch now supports SEH on Windows as well as signals on Linux. - * After receiving a signal, Catch reports failing assertion and then passes the signal onto the previous handler. -* Approx can be used to compare values against strong typedefs (available in C++11 mode only). - * Strong typedefs mean types that are explicitly convertible to double. -* CHECK macro no longer stops executing section if an exception happens. -* Certain characters (space, tab, etc) are now pretty printed. - * This means that a `char c = ' '; REQUIRE(c == '\t');` would be printed as `' ' == '\t'`, instead of ` == 9`. - -##### Fixes: -* Text formatting no longer attempts to access out-of-bounds characters under certain conditions. -* THROW family of assertions no longer trigger `-Wunused-value` on expressions containing explicit cast. -* Breaking into debugger under OS X works again and no longer required `DEBUG` to be defined. -* Compilation no longer breaks under certain compiler if a lambda is used inside assertion macro. - -##### Other: -* Catch's CMakeLists now defines install command. -* Catch's CMakeLists now generates projects with warnings enabled. - - -### 1.6.x - -#### 1.6.1 - -##### Features/ Changes: -* Catch now supports breaking into debugger on Linux - -##### Fixes: -* Generators no longer leak memory (generators are still unsupported in general) -* JUnit reporter now reports UTC timestamps, instead of "tbd" -* `CHECK_THAT` macro is now properly defined as `CATCH_CHECK_THAT` when using `CATCH_` prefixed macros - -##### Other: -* Types with overloaded `&&` operator are no longer evaluated twice when used in an assertion macro. -* The use of `__COUNTER__` is suppressed when Catch is parsed by CLion - * This change is not active when compiling a binary -* Approval tests can now be run on Windows -* CMake will now warn if a file is present in the `include` folder but not is not enumerated as part of the project -* Catch now defines `NOMINMAX` and `WIN32_LEAN_AND_MEAN` before including `windows.h` - * This can be disabled if needed, see [documentation](configuration.md#top) for details. - - -#### 1.6.0 - -##### Cmake/ projects: -* Moved CMakeLists.txt to root, made it friendlier for CLion and generating XCode and VS projects, and removed the manually maintained XCode and VS projects. - -##### Features/ Changes: -* Approx now supports `>=` and `<=` -* Can now use `\` to escape chars in test names on command line -* Standardize C++11 feature toggles - -##### Fixes: -* Blue shell colour -* Missing argument to `CATCH_CHECK_THROWS` -* Don't encode extended ASCII in XML -* use `std::shuffle` on more compilers (fixes deprecation warning/error) -* Use `__COUNTER__` more consistently (where available) - -##### Other: -* Tweaks and changes to scripts - particularly for Approval test - to make them more portable - - -## Even Older versions -Release notes were not maintained prior to v1.6.0, but you should be able to work them out from the Git history - ---- - -[Home](Readme.md#top) + \ No newline at end of file diff --git a/docs/reporters.md b/docs/reporters.md index 496c61a925..e2abfe34d0 100644 --- a/docs/reporters.md +++ b/docs/reporters.md @@ -52,7 +52,7 @@ its machine-readable XML output to file `result-junit.xml`, and the uses ANSI colour codes for colouring the output. Using multiple reporters (or one reporter and one-or-more [event -listeners](event-listener.md#top)) can have surprisingly complex semantics +listeners](event-listeners.md#top)) can have surprisingly complex semantics when using customization points provided to reporters by Catch2, namely capturing stdout/stderr from test cases. diff --git a/docs/test-cases-and-sections.md b/docs/test-cases-and-sections.md index 613bbd14f3..4338549f42 100644 --- a/docs/test-cases-and-sections.md +++ b/docs/test-cases-and-sections.md @@ -1,12 +1,6 @@ # Test cases and sections -**Contents**
-[Tags](#tags)
-[Tag aliases](#tag-aliases)
-[BDD-style test cases](#bdd-style-test-cases)
-[Type parametrised test cases](#type-parametrised-test-cases)
-[Signature based parametrised test cases](#signature-based-parametrised-test-cases)
While Catch fully supports the traditional, xUnit, style of class-based fixtures containing test case methods this is not the preferred style. diff --git a/docs/test-fixtures.md b/docs/test-fixtures.md index e4747c269c..d0f6f9f0cf 100644 --- a/docs/test-fixtures.md +++ b/docs/test-fixtures.md @@ -5,7 +5,7 @@ Although Catch allows you to group tests together as sections within a test case, it can still be convenient, sometimes, to group them using a more traditional test fixture. Catch fully supports this too. You define the test fixture as a simple structure: -```c++ +```cpp class UniqueTestsFixture { private: static int uniqueID; diff --git a/docs/tostring.md b/docs/tostring.md index adce3cc764..735f42e4ee 100644 --- a/docs/tostring.md +++ b/docs/tostring.md @@ -1,13 +1,6 @@ # String conversions -**Contents**
-[operator << overload for std::ostream](#operator--overload-for-stdostream)
-[Catch::StringMaker specialisation](#catchstringmaker-specialisation)
-[Catch::is_range specialisation](#catchis_range-specialisation)
-[Exceptions](#exceptions)
-[Enums](#enums)
-[Floating point precision](#floating-point-precision)
Catch needs to be able to convert types you use in assertions and logging expressions into strings (for logging and reporting purposes). diff --git a/docs/tutorial.md b/docs/tutorial.md index 9216e9fd75..d2772fc302 100644 --- a/docs/tutorial.md +++ b/docs/tutorial.md @@ -1,14 +1,6 @@ # Tutorial -**Contents**
-[Getting Catch2](#getting-catch2)
-[Writing tests](#writing-tests)
-[Test cases and sections](#test-cases-and-sections)
-[BDD style testing](#bdd-style-testing)
-[Data and Type driven tests](#data-and-type-driven-tests)
-[Next steps](#next-steps)
- ## Getting Catch2 @@ -23,13 +15,13 @@ the included header with `catch_amalgamated.hpp`. Let's start with a really simple example ([code](../examples/010-TestCase.cpp)). Say you have written a function to calculate factorials and now you want to test it (let's leave aside TDD for now). -```c++ +```cpp unsigned int Factorial( unsigned int number ) { return number <= 1 ? number : Factorial(number-1)*number; } ``` -```c++ +```cpp #include unsigned int Factorial( unsigned int number ) { @@ -51,7 +43,7 @@ The problem is that `Factorial(0)` should return 1 (due to [its definition](https://en.wikipedia.org/wiki/Factorial#Factorial_of_zero)). Let's add that as an assertion to the test case: -```c++ +```cpp TEST_CASE( "Factorials are computed", "[factorial]" ) { REQUIRE( Factorial(0) == 1 ); REQUIRE( Factorial(1) == 1 ); @@ -76,7 +68,7 @@ Note that the output contains both the original expression, to the `Factorial` function: `0`. We can fix this bug by slightly modifying the `Factorial` function to: -```c++ +```cpp unsigned int Factorial( unsigned int number ) { return number > 1 ? Factorial(number-1)*number : 1; } @@ -117,7 +109,7 @@ However, their use in Catch2 is rare, because idiomatic Catch2 tests instead use _sections_ to share setup and teardown code between test code. This is best explained through an example ([code](../examples/100-Fix-Section.cpp)): -```c++ +```cpp TEST_CASE( "vectors can be sized and resized", "[vector]" ) { std::vector v( 5 ); diff --git a/package.json b/package.json new file mode 100644 index 0000000000..b6b8914ecc --- /dev/null +++ b/package.json @@ -0,0 +1,11 @@ +{ + "devDependencies": { + "vitepress": "^1.0.0-alpha.4", + "vue": "^3.2.37" + }, + "scripts": { + "docs:dev": "vitepress dev docs", + "docs:build": "vitepress build docs", + "docs:serve": "vitepress serve docs" + } +} diff --git a/yarn.lock b/yarn.lock new file mode 100644 index 0000000000..d0a40e4819 --- /dev/null +++ b/yarn.lock @@ -0,0 +1,605 @@ +# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. +# yarn lockfile v1 + + +"@algolia/autocomplete-core@1.7.1": + version "1.7.1" + resolved "https://registry.yarnpkg.com/@algolia/autocomplete-core/-/autocomplete-core-1.7.1.tgz#025538b8a9564a9f3dd5bcf8a236d6951c76c7d1" + integrity sha512-eiZw+fxMzNQn01S8dA/hcCpoWCOCwcIIEUtHHdzN5TGB3IpzLbuhqFeTfh2OUhhgkE8Uo17+wH+QJ/wYyQmmzg== + dependencies: + "@algolia/autocomplete-shared" "1.7.1" + +"@algolia/autocomplete-preset-algolia@1.7.1": + version "1.7.1" + resolved "https://registry.yarnpkg.com/@algolia/autocomplete-preset-algolia/-/autocomplete-preset-algolia-1.7.1.tgz#7dadc5607097766478014ae2e9e1c9c4b3f957c8" + integrity sha512-pJwmIxeJCymU1M6cGujnaIYcY3QPOVYZOXhFkWVM7IxKzy272BwCvMFMyc5NpG/QmiObBxjo7myd060OeTNJXg== + dependencies: + "@algolia/autocomplete-shared" "1.7.1" + +"@algolia/autocomplete-shared@1.7.1": + version "1.7.1" + resolved "https://registry.yarnpkg.com/@algolia/autocomplete-shared/-/autocomplete-shared-1.7.1.tgz#95c3a0b4b78858fed730cf9c755b7d1cd0c82c74" + integrity sha512-eTmGVqY3GeyBTT8IWiB2K5EuURAqhnumfktAEoHxfDY2o7vg2rSnO16ZtIG0fMgt3py28Vwgq42/bVEuaQV7pg== + +"@algolia/cache-browser-local-storage@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/cache-browser-local-storage/-/cache-browser-local-storage-4.13.1.tgz#ffacb9230119f77de1a6f163b83680be999110e4" + integrity sha512-UAUVG2PEfwd/FfudsZtYnidJ9eSCpS+LW9cQiesePQLz41NAcddKxBak6eP2GErqyFagSlnVXe/w2E9h2m2ttg== + dependencies: + "@algolia/cache-common" "4.13.1" + +"@algolia/cache-common@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/cache-common/-/cache-common-4.13.1.tgz#c933fdec9f73b4f7c69d5751edc92eee4a63d76b" + integrity sha512-7Vaf6IM4L0Jkl3sYXbwK+2beQOgVJ0mKFbz/4qSxKd1iy2Sp77uTAazcX+Dlexekg1fqGUOSO7HS4Sx47ZJmjA== + +"@algolia/cache-in-memory@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/cache-in-memory/-/cache-in-memory-4.13.1.tgz#c19baa67b4597e1a93e987350613ab3b88768832" + integrity sha512-pZzybCDGApfA/nutsFK1P0Sbsq6fYJU3DwIvyKg4pURerlJM4qZbB9bfLRef0FkzfQu7W11E4cVLCIOWmyZeuQ== + dependencies: + "@algolia/cache-common" "4.13.1" + +"@algolia/client-account@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/client-account/-/client-account-4.13.1.tgz#fea591943665477a23922ab31863ad0732e26c66" + integrity sha512-TFLiZ1KqMiir3FNHU+h3b0MArmyaHG+eT8Iojio6TdpeFcAQ1Aiy+2gb3SZk3+pgRJa/BxGmDkRUwE5E/lv3QQ== + dependencies: + "@algolia/client-common" "4.13.1" + "@algolia/client-search" "4.13.1" + "@algolia/transporter" "4.13.1" + +"@algolia/client-analytics@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/client-analytics/-/client-analytics-4.13.1.tgz#5275956b2d0d16997148f2085f1701b6c39ecc32" + integrity sha512-iOS1JBqh7xaL5x00M5zyluZ9+9Uy9GqtYHv/2SMuzNW1qP7/0doz1lbcsP3S7KBbZANJTFHUOfuqyRLPk91iFA== + dependencies: + "@algolia/client-common" "4.13.1" + "@algolia/client-search" "4.13.1" + "@algolia/requester-common" "4.13.1" + "@algolia/transporter" "4.13.1" + +"@algolia/client-common@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/client-common/-/client-common-4.13.1.tgz#3bf9e3586f20ef85bbb56ccca390f7dbe57c8f4f" + integrity sha512-LcDoUE0Zz3YwfXJL6lJ2OMY2soClbjrrAKB6auYVMNJcoKZZ2cbhQoFR24AYoxnGUYBER/8B+9sTBj5bj/Gqbg== + dependencies: + "@algolia/requester-common" "4.13.1" + "@algolia/transporter" "4.13.1" + +"@algolia/client-personalization@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/client-personalization/-/client-personalization-4.13.1.tgz#438a1f58576ef19c4ad4addb8417bdacfe2fce2e" + integrity sha512-1CqrOW1ypVrB4Lssh02hP//YxluoIYXAQCpg03L+/RiXJlCs+uIqlzC0ctpQPmxSlTK6h07kr50JQoYH/TIM9w== + dependencies: + "@algolia/client-common" "4.13.1" + "@algolia/requester-common" "4.13.1" + "@algolia/transporter" "4.13.1" + +"@algolia/client-search@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/client-search/-/client-search-4.13.1.tgz#5501deed01e23c33d4aaa9f9eb96a849f0fce313" + integrity sha512-YQKYA83MNRz3FgTNM+4eRYbSmHi0WWpo019s5SeYcL3HUan/i5R09VO9dk3evELDFJYciiydSjbsmhBzbpPP2A== + dependencies: + "@algolia/client-common" "4.13.1" + "@algolia/requester-common" "4.13.1" + "@algolia/transporter" "4.13.1" + +"@algolia/logger-common@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/logger-common/-/logger-common-4.13.1.tgz#4221378e701e3f1eacaa051bcd4ba1f25ddfaf4d" + integrity sha512-L6slbL/OyZaAXNtS/1A8SAbOJeEXD5JcZeDCPYDqSTYScfHu+2ePRTDMgUTY4gQ7HsYZ39N1LujOd8WBTmM2Aw== + +"@algolia/logger-console@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/logger-console/-/logger-console-4.13.1.tgz#423d358e4992dd4bceab0d9a4e99d1fd68107043" + integrity sha512-7jQOTftfeeLlnb3YqF8bNgA2GZht7rdKkJ31OCeSH2/61haO0tWPoNRjZq9XLlgMQZH276pPo0NdiArcYPHjCA== + dependencies: + "@algolia/logger-common" "4.13.1" + +"@algolia/requester-browser-xhr@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/requester-browser-xhr/-/requester-browser-xhr-4.13.1.tgz#f8ea79233cf6f0392feaf31e35a6b40d68c5bc9e" + integrity sha512-oa0CKr1iH6Nc7CmU6RE7TnXMjHnlyp7S80pP/LvZVABeJHX3p/BcSCKovNYWWltgTxUg0U1o+2uuy8BpMKljwA== + dependencies: + "@algolia/requester-common" "4.13.1" + +"@algolia/requester-common@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/requester-common/-/requester-common-4.13.1.tgz#daea143d15ab6ed3909c4c45877f1b6c36a16179" + integrity sha512-eGVf0ID84apfFEuXsaoSgIxbU3oFsIbz4XiotU3VS8qGCJAaLVUC5BUJEkiFENZIhon7hIB4d0RI13HY4RSA+w== + +"@algolia/requester-node-http@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/requester-node-http/-/requester-node-http-4.13.1.tgz#32c63d4c009f22d97e396406de7af9b66fb8e89d" + integrity sha512-7C0skwtLdCz5heKTVe/vjvrqgL/eJxmiEjHqXdtypcE5GCQCYI15cb+wC4ytYioZDMiuDGeVYmCYImPoEgUGPw== + dependencies: + "@algolia/requester-common" "4.13.1" + +"@algolia/transporter@4.13.1": + version "4.13.1" + resolved "https://registry.yarnpkg.com/@algolia/transporter/-/transporter-4.13.1.tgz#509e03e9145102843d5be4a031c521f692d4e8d6" + integrity sha512-pICnNQN7TtrcYJqqPEXByV8rJ8ZRU2hCiIKLTLRyNpghtQG3VAFk6fVtdzlNfdUGZcehSKGarPIZEHlQXnKjgw== + dependencies: + "@algolia/cache-common" "4.13.1" + "@algolia/logger-common" "4.13.1" + "@algolia/requester-common" "4.13.1" + +"@babel/parser@^7.16.4": + version "7.18.8" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.18.8.tgz#822146080ac9c62dac0823bb3489622e0bc1cbdf" + integrity sha512-RSKRfYX20dyH+elbJK2uqAkVyucL+xXzhqlMD5/ZXx+dAAwpyB7HsvnHe/ZUGOF+xLr5Wx9/JoXVTj6BQE2/oA== + +"@docsearch/css@3.1.1", "@docsearch/css@^3.0.0": + version "3.1.1" + resolved "https://registry.yarnpkg.com/@docsearch/css/-/css-3.1.1.tgz#e0976bf995e383f8ee8657306311b9cb95016330" + integrity sha512-utLgg7E1agqQeqCJn05DWC7XXMk4tMUUnL7MZupcknRu2OzGN13qwey2qA/0NAKkVBGugiWtON0+rlU0QIPojg== + +"@docsearch/js@^3.0.0": + version "3.1.1" + resolved "https://registry.yarnpkg.com/@docsearch/js/-/js-3.1.1.tgz#fbcf85d034b11ae15397310ef117c7d6fb4e6871" + integrity sha512-bt7l2aKRoSnLUuX+s4LVQ1a7AF2c9myiZNv5uvQCePG5tpvVGpwrnMwqVXOUJn9q6FwVVhOrQMO/t+QmnnAEUw== + dependencies: + "@docsearch/react" "3.1.1" + preact "^10.0.0" + +"@docsearch/react@3.1.1": + version "3.1.1" + resolved "https://registry.yarnpkg.com/@docsearch/react/-/react-3.1.1.tgz#3dffb5db8cf9eb95d6e732cf038264bfc10191ed" + integrity sha512-cfoql4qvtsVRqBMYxhlGNpvyy/KlCoPqjIsJSZYqYf9AplZncKjLBTcwBu6RXFMVCe30cIFljniI4OjqAU67pQ== + dependencies: + "@algolia/autocomplete-core" "1.7.1" + "@algolia/autocomplete-preset-algolia" "1.7.1" + "@docsearch/css" "3.1.1" + algoliasearch "^4.0.0" + +"@types/web-bluetooth@^0.0.14": + version "0.0.14" + resolved "https://registry.yarnpkg.com/@types/web-bluetooth/-/web-bluetooth-0.0.14.tgz#94e175b53623384bff1f354cdb3197a8d63cdbe5" + integrity sha512-5d2RhCard1nQUC3aHcq/gHzWYO6K0WJmAbjO7mQJgCQKtZpgXxv1rOM6O/dBDhDYYVutk1sciOgNSe+5YyfM8A== + +"@vitejs/plugin-vue@^2.3.2": + version "2.3.3" + resolved "https://registry.yarnpkg.com/@vitejs/plugin-vue/-/plugin-vue-2.3.3.tgz#fbf80cc039b82ac21a1acb0f0478de8f61fbf600" + integrity sha512-SmQLDyhz+6lGJhPELsBdzXGc+AcaT8stgkbiTFGpXPe8Tl1tJaBw1A6pxDqDuRsVkD8uscrkx3hA7QDOoKYtyw== + +"@vue/compiler-core@3.2.37": + version "3.2.37" + resolved "https://registry.yarnpkg.com/@vue/compiler-core/-/compiler-core-3.2.37.tgz#b3c42e04c0e0f2c496ff1784e543fbefe91e215a" + integrity sha512-81KhEjo7YAOh0vQJoSmAD68wLfYqJvoiD4ulyedzF+OEk/bk6/hx3fTNVfuzugIIaTrOx4PGx6pAiBRe5e9Zmg== + dependencies: + "@babel/parser" "^7.16.4" + "@vue/shared" "3.2.37" + estree-walker "^2.0.2" + source-map "^0.6.1" + +"@vue/compiler-dom@3.2.37": + version "3.2.37" + resolved "https://registry.yarnpkg.com/@vue/compiler-dom/-/compiler-dom-3.2.37.tgz#10d2427a789e7c707c872da9d678c82a0c6582b5" + integrity sha512-yxJLH167fucHKxaqXpYk7x8z7mMEnXOw3G2q62FTkmsvNxu4FQSu5+3UMb+L7fjKa26DEzhrmCxAgFLLIzVfqQ== + dependencies: + "@vue/compiler-core" "3.2.37" + "@vue/shared" "3.2.37" + +"@vue/compiler-sfc@3.2.37": + version "3.2.37" + resolved "https://registry.yarnpkg.com/@vue/compiler-sfc/-/compiler-sfc-3.2.37.tgz#3103af3da2f40286edcd85ea495dcb35bc7f5ff4" + integrity sha512-+7i/2+9LYlpqDv+KTtWhOZH+pa8/HnX/905MdVmAcI/mPQOBwkHHIzrsEsucyOIZQYMkXUiTkmZq5am/NyXKkg== + dependencies: + "@babel/parser" "^7.16.4" + "@vue/compiler-core" "3.2.37" + "@vue/compiler-dom" "3.2.37" + "@vue/compiler-ssr" "3.2.37" + "@vue/reactivity-transform" "3.2.37" + "@vue/shared" "3.2.37" + estree-walker "^2.0.2" + magic-string "^0.25.7" + postcss "^8.1.10" + source-map "^0.6.1" + +"@vue/compiler-ssr@3.2.37": + version "3.2.37" + resolved "https://registry.yarnpkg.com/@vue/compiler-ssr/-/compiler-ssr-3.2.37.tgz#4899d19f3a5fafd61524a9d1aee8eb0505313cff" + integrity sha512-7mQJD7HdXxQjktmsWp/J67lThEIcxLemz1Vb5I6rYJHR5vI+lON3nPGOH3ubmbvYGt8xEUaAr1j7/tIFWiEOqw== + dependencies: + "@vue/compiler-dom" "3.2.37" + "@vue/shared" "3.2.37" + +"@vue/devtools-api@^6.1.4": + version "6.2.0" + resolved "https://registry.yarnpkg.com/@vue/devtools-api/-/devtools-api-6.2.0.tgz#e3dc98a0cce8e87292745e2d24c9ee8c274a023b" + integrity sha512-pF1G4wky+hkifDiZSWn8xfuLOJI1ZXtuambpBEYaf7Xaf6zC/pM29rvAGpd3qaGXnr4BAXU1Pxz/VfvBGwexGA== + +"@vue/reactivity-transform@3.2.37": + version "3.2.37" + resolved "https://registry.yarnpkg.com/@vue/reactivity-transform/-/reactivity-transform-3.2.37.tgz#0caa47c4344df4ae59f5a05dde2a8758829f8eca" + integrity sha512-IWopkKEb+8qpu/1eMKVeXrK0NLw9HicGviJzhJDEyfxTR9e1WtpnnbYkJWurX6WwoFP0sz10xQg8yL8lgskAZg== + dependencies: + "@babel/parser" "^7.16.4" + "@vue/compiler-core" "3.2.37" + "@vue/shared" "3.2.37" + estree-walker "^2.0.2" + magic-string "^0.25.7" + +"@vue/reactivity@3.2.37": + version "3.2.37" + resolved "https://registry.yarnpkg.com/@vue/reactivity/-/reactivity-3.2.37.tgz#5bc3847ac58828e2b78526e08219e0a1089f8848" + integrity sha512-/7WRafBOshOc6m3F7plwzPeCu/RCVv9uMpOwa/5PiY1Zz+WLVRWiy0MYKwmg19KBdGtFWsmZ4cD+LOdVPcs52A== + dependencies: + "@vue/shared" "3.2.37" + +"@vue/runtime-core@3.2.37": + version "3.2.37" + resolved "https://registry.yarnpkg.com/@vue/runtime-core/-/runtime-core-3.2.37.tgz#7ba7c54bb56e5d70edfc2f05766e1ca8519966e3" + integrity sha512-JPcd9kFyEdXLl/i0ClS7lwgcs0QpUAWj+SKX2ZC3ANKi1U4DOtiEr6cRqFXsPwY5u1L9fAjkinIdB8Rz3FoYNQ== + dependencies: + "@vue/reactivity" "3.2.37" + "@vue/shared" "3.2.37" + +"@vue/runtime-dom@3.2.37": + version "3.2.37" + resolved "https://registry.yarnpkg.com/@vue/runtime-dom/-/runtime-dom-3.2.37.tgz#002bdc8228fa63949317756fb1e92cdd3f9f4bbd" + integrity sha512-HimKdh9BepShW6YozwRKAYjYQWg9mQn63RGEiSswMbW+ssIht1MILYlVGkAGGQbkhSh31PCdoUcfiu4apXJoPw== + dependencies: + "@vue/runtime-core" "3.2.37" + "@vue/shared" "3.2.37" + csstype "^2.6.8" + +"@vue/server-renderer@3.2.37": + version "3.2.37" + resolved "https://registry.yarnpkg.com/@vue/server-renderer/-/server-renderer-3.2.37.tgz#840a29c8dcc29bddd9b5f5ffa22b95c0e72afdfc" + integrity sha512-kLITEJvaYgZQ2h47hIzPh2K3jG8c1zCVbp/o/bzQOyvzaKiCquKS7AaioPI28GNxIsE/zSx+EwWYsNxDCX95MA== + dependencies: + "@vue/compiler-ssr" "3.2.37" + "@vue/shared" "3.2.37" + +"@vue/shared@3.2.37": + version "3.2.37" + resolved "https://registry.yarnpkg.com/@vue/shared/-/shared-3.2.37.tgz#8e6adc3f2759af52f0e85863dfb0b711ecc5c702" + integrity sha512-4rSJemR2NQIo9Klm1vabqWjD8rs/ZaJSzMxkMNeJS6lHiUjjUeYFbooN19NgFjztubEKh3WlZUeOLVdbbUWHsw== + +"@vueuse/core@^8.5.0": + version "8.9.1" + resolved "https://registry.yarnpkg.com/@vueuse/core/-/core-8.9.1.tgz#9e986c9847ec41996321709494176ad54810b9c9" + integrity sha512-a7goYb/gJxjXRBw4Fr/jEACiN33ghwM1ohJVu+Zwsr3lNL4qCQ1nU+ogta98lNg5hXJxWj7mYEmQDjjyWOu5nA== + dependencies: + "@types/web-bluetooth" "^0.0.14" + "@vueuse/metadata" "8.9.1" + "@vueuse/shared" "8.9.1" + vue-demi "*" + +"@vueuse/metadata@8.9.1": + version "8.9.1" + resolved "https://registry.yarnpkg.com/@vueuse/metadata/-/metadata-8.9.1.tgz#5699e7d9a67894b8490cfb61c37beb0428e6fe07" + integrity sha512-6LADOlyl3oENHa9dsoY7LXjU1Mh14DnpM6ztETI3hpm5ZffOMIG5CB2Q6aEZfIvYr1lkJVmG2L82wFKk7VRfIA== + +"@vueuse/shared@8.9.1": + version "8.9.1" + resolved "https://registry.yarnpkg.com/@vueuse/shared/-/shared-8.9.1.tgz#1b48414c06d1e3d14fe3f32bf72f5fab35451a3d" + integrity sha512-klZfn7ijI3juqVgpfQVrrlBh4uTFajwSCWm8Cdt45Kg26b1LZ9jn9n7J6GhmkFay5016GnjjivQoekQSMeJNUg== + dependencies: + vue-demi "*" + +algoliasearch@^4.0.0: + version "4.13.1" + resolved "https://registry.yarnpkg.com/algoliasearch/-/algoliasearch-4.13.1.tgz#54195c41c9e4bd13ed64982248cf49d4576974fe" + integrity sha512-dtHUSE0caWTCE7liE1xaL+19AFf6kWEcyn76uhcitWpntqvicFHXKFoZe5JJcv9whQOTRM6+B8qJz6sFj+rDJA== + dependencies: + "@algolia/cache-browser-local-storage" "4.13.1" + "@algolia/cache-common" "4.13.1" + "@algolia/cache-in-memory" "4.13.1" + "@algolia/client-account" "4.13.1" + "@algolia/client-analytics" "4.13.1" + "@algolia/client-common" "4.13.1" + "@algolia/client-personalization" "4.13.1" + "@algolia/client-search" "4.13.1" + "@algolia/logger-common" "4.13.1" + "@algolia/logger-console" "4.13.1" + "@algolia/requester-browser-xhr" "4.13.1" + "@algolia/requester-common" "4.13.1" + "@algolia/requester-node-http" "4.13.1" + "@algolia/transporter" "4.13.1" + +body-scroll-lock@^4.0.0-beta.0: + version "4.0.0-beta.0" + resolved "https://registry.yarnpkg.com/body-scroll-lock/-/body-scroll-lock-4.0.0-beta.0.tgz#4f78789d10e6388115c0460cd6d7d4dd2bbc4f7e" + integrity sha512-a7tP5+0Mw3YlUJcGAKUqIBkYYGlYxk2fnCasq/FUph1hadxlTRjF+gAcZksxANnaMnALjxEddmSi/H3OR8ugcQ== + +csstype@^2.6.8: + version "2.6.20" + resolved "https://registry.yarnpkg.com/csstype/-/csstype-2.6.20.tgz#9229c65ea0b260cf4d3d997cb06288e36a8d6dda" + integrity sha512-/WwNkdXfckNgw6S5R125rrW8ez139lBHWouiBvX8dfMFtcn6V81REDqnH7+CRpRipfYlyU1CmOnOxrmGcFOjeA== + +esbuild-android-64@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-android-64/-/esbuild-android-64-0.14.49.tgz#9e4682c36dcf6e7b71b73d2a3723a96e0fdc5054" + integrity sha512-vYsdOTD+yi+kquhBiFWl3tyxnj2qZJsl4tAqwhT90ktUdnyTizgle7TjNx6Ar1bN7wcwWqZ9QInfdk2WVagSww== + +esbuild-android-arm64@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-android-arm64/-/esbuild-android-arm64-0.14.49.tgz#9861b1f7e57d1dd1f23eeef6198561c5f34b51f6" + integrity sha512-g2HGr/hjOXCgSsvQZ1nK4nW/ei8JUx04Li74qub9qWrStlysaVmadRyTVuW32FGIpLQyc5sUjjZopj49eGGM2g== + +esbuild-darwin-64@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-darwin-64/-/esbuild-darwin-64-0.14.49.tgz#fd30a5ebe28704a3a117126c60f98096c067c8d1" + integrity sha512-3rvqnBCtX9ywso5fCHixt2GBCUsogNp9DjGmvbBohh31Ces34BVzFltMSxJpacNki96+WIcX5s/vum+ckXiLYg== + +esbuild-darwin-arm64@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.14.49.tgz#c04a3a57dad94a972c66a697a68a25aa25947f41" + integrity sha512-XMaqDxO846srnGlUSJnwbijV29MTKUATmOLyQSfswbK/2X5Uv28M9tTLUJcKKxzoo9lnkYPsx2o8EJcTYwCs/A== + +esbuild-freebsd-64@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-freebsd-64/-/esbuild-freebsd-64-0.14.49.tgz#c404dbd66c98451395b1eef0fa38b73030a7be82" + integrity sha512-NJ5Q6AjV879mOHFri+5lZLTp5XsO2hQ+KSJYLbfY9DgCu8s6/Zl2prWXVANYTeCDLlrIlNNYw8y34xqyLDKOmQ== + +esbuild-freebsd-arm64@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.14.49.tgz#b62cec96138ebc5937240ce3e1b97902963ea74a" + integrity sha512-lFLtgXnAc3eXYqj5koPlBZvEbBSOSUbWO3gyY/0+4lBdRqELyz4bAuamHvmvHW5swJYL7kngzIZw6kdu25KGOA== + +esbuild-linux-32@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-linux-32/-/esbuild-linux-32-0.14.49.tgz#495b1cc011b8c64d8bbaf65509c1e7135eb9ddbf" + integrity sha512-zTTH4gr2Kb8u4QcOpTDVn7Z8q7QEIvFl/+vHrI3cF6XOJS7iEI1FWslTo3uofB2+mn6sIJEQD9PrNZKoAAMDiA== + +esbuild-linux-64@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-linux-64/-/esbuild-linux-64-0.14.49.tgz#3f28dd8f986e6ff42f38888ee435a9b1fb916a56" + integrity sha512-hYmzRIDzFfLrB5c1SknkxzM8LdEUOusp6M2TnuQZJLRtxTgyPnZZVtyMeCLki0wKgYPXkFsAVhi8vzo2mBNeTg== + +esbuild-linux-arm64@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-linux-arm64/-/esbuild-linux-arm64-0.14.49.tgz#a52e99ae30246566dc5f33e835aa6ca98ef70e33" + integrity sha512-KLQ+WpeuY+7bxukxLz5VgkAAVQxUv67Ft4DmHIPIW+2w3ObBPQhqNoeQUHxopoW/aiOn3m99NSmSV+bs4BSsdA== + +esbuild-linux-arm@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-linux-arm/-/esbuild-linux-arm-0.14.49.tgz#7c33d05a64ec540cf7474834adaa57b3167bbe97" + integrity sha512-iE3e+ZVv1Qz1Sy0gifIsarJMQ89Rpm9mtLSRtG3AH0FPgAzQ5Z5oU6vYzhc/3gSPi2UxdCOfRhw2onXuFw/0lg== + +esbuild-linux-mips64le@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.14.49.tgz#ed062bd844b587be649443831eb84ba304685f25" + integrity sha512-n+rGODfm8RSum5pFIqFQVQpYBw+AztL8s6o9kfx7tjfK0yIGF6tm5HlG6aRjodiiKkH2xAiIM+U4xtQVZYU4rA== + +esbuild-linux-ppc64le@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.14.49.tgz#c0786fb5bddffd90c10a2078181513cbaf077958" + integrity sha512-WP9zR4HX6iCBmMFH+XHHng2LmdoIeUmBpL4aL2TR8ruzXyT4dWrJ5BSbT8iNo6THN8lod6GOmYDLq/dgZLalGw== + +esbuild-linux-riscv64@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-linux-riscv64/-/esbuild-linux-riscv64-0.14.49.tgz#579b0e7cc6fce4bfc698e991a52503bb616bec49" + integrity sha512-h66ORBz+Dg+1KgLvzTVQEA1LX4XBd1SK0Fgbhhw4akpG/YkN8pS6OzYI/7SGENiN6ao5hETRDSkVcvU9NRtkMQ== + +esbuild-linux-s390x@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-linux-s390x/-/esbuild-linux-s390x-0.14.49.tgz#09eb15c753e249a500b4e28d07c5eef7524a9740" + integrity sha512-DhrUoFVWD+XmKO1y7e4kNCqQHPs6twz6VV6Uezl/XHYGzM60rBewBF5jlZjG0nCk5W/Xy6y1xWeopkrhFFM0sQ== + +esbuild-netbsd-64@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-netbsd-64/-/esbuild-netbsd-64-0.14.49.tgz#f7337cd2bddb7cc9d100d19156f36c9ca117b58d" + integrity sha512-BXaUwFOfCy2T+hABtiPUIpWjAeWK9P8O41gR4Pg73hpzoygVGnj0nI3YK4SJhe52ELgtdgWP/ckIkbn2XaTxjQ== + +esbuild-openbsd-64@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-openbsd-64/-/esbuild-openbsd-64-0.14.49.tgz#1f8bdc49f8a44396e73950a3fb6b39828563631d" + integrity sha512-lP06UQeLDGmVPw9Rg437Btu6J9/BmyhdoefnQ4gDEJTtJvKtQaUcOQrhjTq455ouZN4EHFH1h28WOJVANK41kA== + +esbuild-sunos-64@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-sunos-64/-/esbuild-sunos-64-0.14.49.tgz#47d042739365b61aa8ca642adb69534a8eef9f7a" + integrity sha512-4c8Zowp+V3zIWje329BeLbGh6XI9c/rqARNaj5yPHdC61pHI9UNdDxT3rePPJeWcEZVKjkiAS6AP6kiITp7FSw== + +esbuild-windows-32@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-windows-32/-/esbuild-windows-32-0.14.49.tgz#79198c88ec9bde163c18a6b430c34eab098ec21a" + integrity sha512-q7Rb+J9yHTeKr9QTPDYkqfkEj8/kcKz9lOabDuvEXpXuIcosWCJgo5Z7h/L4r7rbtTH4a8U2FGKb6s1eeOHmJA== + +esbuild-windows-64@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-windows-64/-/esbuild-windows-64-0.14.49.tgz#b36b230d18d1ee54008e08814c4799c7806e8c79" + integrity sha512-+Cme7Ongv0UIUTniPqfTX6mJ8Deo7VXw9xN0yJEN1lQMHDppTNmKwAM3oGbD/Vqff+07K2gN0WfNkMohmG+dVw== + +esbuild-windows-arm64@0.14.49: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild-windows-arm64/-/esbuild-windows-arm64-0.14.49.tgz#d83c03ff6436caf3262347cfa7e16b0a8049fae7" + integrity sha512-v+HYNAXzuANrCbbLFJ5nmO3m5y2PGZWLe3uloAkLt87aXiO2mZr3BTmacZdjwNkNEHuH3bNtN8cak+mzVjVPfA== + +esbuild@^0.14.27: + version "0.14.49" + resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.14.49.tgz#b82834760eba2ddc17b44f05cfcc0aaca2bae492" + integrity sha512-/TlVHhOaq7Yz8N1OJrjqM3Auzo5wjvHFLk+T8pIue+fhnhIMpfAzsG6PLVMbFveVxqD2WOp3QHei+52IMUNmCw== + optionalDependencies: + esbuild-android-64 "0.14.49" + esbuild-android-arm64 "0.14.49" + esbuild-darwin-64 "0.14.49" + esbuild-darwin-arm64 "0.14.49" + esbuild-freebsd-64 "0.14.49" + esbuild-freebsd-arm64 "0.14.49" + esbuild-linux-32 "0.14.49" + esbuild-linux-64 "0.14.49" + esbuild-linux-arm "0.14.49" + esbuild-linux-arm64 "0.14.49" + esbuild-linux-mips64le "0.14.49" + esbuild-linux-ppc64le "0.14.49" + esbuild-linux-riscv64 "0.14.49" + esbuild-linux-s390x "0.14.49" + esbuild-netbsd-64 "0.14.49" + esbuild-openbsd-64 "0.14.49" + esbuild-sunos-64 "0.14.49" + esbuild-windows-32 "0.14.49" + esbuild-windows-64 "0.14.49" + esbuild-windows-arm64 "0.14.49" + +estree-walker@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-2.0.2.tgz#52f010178c2a4c117a7757cfe942adb7d2da4cac" + integrity sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w== + +fsevents@~2.3.2: + version "2.3.2" + resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.3.2.tgz#8a526f78b8fdf4623b709e0b975c52c24c02fd1a" + integrity sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA== + +function-bind@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" + integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== + +has@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" + integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== + dependencies: + function-bind "^1.1.1" + +is-core-module@^2.9.0: + version "2.9.0" + resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.9.0.tgz#e1c34429cd51c6dd9e09e0799e396e27b19a9c69" + integrity sha512-+5FPy5PnwmO3lvfMb0AsoPaBG+5KHUI0wYFXOtYPnVVVspTFUuMZNfNaNVRt3FZadstu2c8x23vykRW/NBoU6A== + dependencies: + has "^1.0.3" + +jsonc-parser@^3.0.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/jsonc-parser/-/jsonc-parser-3.1.0.tgz#73b8f0e5c940b83d03476bc2e51a20ef0932615d" + integrity sha512-DRf0QjnNeCUds3xTjKlQQ3DpJD51GvDjJfnxUVWg6PZTo2otSm+slzNAxU/35hF8/oJIKoG9slq30JYOsF2azg== + +magic-string@^0.25.7: + version "0.25.9" + resolved "https://registry.yarnpkg.com/magic-string/-/magic-string-0.25.9.tgz#de7f9faf91ef8a1c91d02c2e5314c8277dbcdd1c" + integrity sha512-RmF0AsMzgt25qzqqLc1+MbHmhdx0ojF2Fvs4XnOqz2ZOBXzzkEwc/dJQZCYHAn7v1jbVOjAZfK8msRn4BxO4VQ== + dependencies: + sourcemap-codec "^1.4.8" + +nanoid@^3.3.4: + version "3.3.4" + resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.4.tgz#730b67e3cd09e2deacf03c027c81c9d9dbc5e8ab" + integrity sha512-MqBkQh/OHTS2egovRtLk45wEyNXwF+cokD+1YPf9u5VfJiRdAiRwB2froX5Co9Rh20xs4siNPm8naNotSD6RBw== + +path-parse@^1.0.7: + version "1.0.7" + resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.7.tgz#fbc114b60ca42b30d9daf5858e4bd68bbedb6735" + integrity sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw== + +picocolors@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.0.0.tgz#cb5bdc74ff3f51892236eaf79d68bc44564ab81c" + integrity sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ== + +postcss@^8.1.10, postcss@^8.4.13: + version "8.4.14" + resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.4.14.tgz#ee9274d5622b4858c1007a74d76e42e56fd21caf" + integrity sha512-E398TUmfAYFPBSdzgeieK2Y1+1cpdxJx8yXbK/m57nRhKSmk1GB2tO4lbLBtlkfPQTDKfe4Xqv1ASWPpayPEig== + dependencies: + nanoid "^3.3.4" + picocolors "^1.0.0" + source-map-js "^1.0.2" + +preact@^10.0.0: + version "10.9.0" + resolved "https://registry.yarnpkg.com/preact/-/preact-10.9.0.tgz#69b282b26926b66481c9ae3450cf68610fee29ff" + integrity sha512-jO6/OvCRL+OT8gst/+Q2ir7dMybZAX8ioP02Zmzh3BkQMHLyqZSujvxbUriXvHi8qmhcHKC2Gwbog6Kt+YTh+Q== + +resolve@^1.22.0: + version "1.22.1" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.1.tgz#27cb2ebb53f91abb49470a928bba7558066ac177" + integrity sha512-nBpuuYuY5jFsli/JIs1oldw6fOQCBioohqWZg/2hiaOybXOft4lonv85uDOKXdf8rhyK159cxU5cDcK/NKk8zw== + dependencies: + is-core-module "^2.9.0" + path-parse "^1.0.7" + supports-preserve-symlinks-flag "^1.0.0" + +rollup@^2.59.0: + version "2.76.0" + resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.76.0.tgz#c69fe03db530ac53fcb9523b3caa0d3c0b9491a1" + integrity sha512-9jwRIEY1jOzKLj3nsY/yot41r19ITdQrhs+q3ggNWhr9TQgduHqANvPpS32RNpzGklJu3G1AJfvlZLi/6wFgWA== + optionalDependencies: + fsevents "~2.3.2" + +shiki@^0.10.1: + version "0.10.1" + resolved "https://registry.yarnpkg.com/shiki/-/shiki-0.10.1.tgz#6f9a16205a823b56c072d0f1a0bcd0f2646bef14" + integrity sha512-VsY7QJVzU51j5o1+DguUd+6vmCmZ5v/6gYu4vyYAhzjuNQU6P/vmSy4uQaOhvje031qQMiW0d2BwgMH52vqMng== + dependencies: + jsonc-parser "^3.0.0" + vscode-oniguruma "^1.6.1" + vscode-textmate "5.2.0" + +source-map-js@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/source-map-js/-/source-map-js-1.0.2.tgz#adbc361d9c62df380125e7f161f71c826f1e490c" + integrity sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw== + +source-map@^0.6.1: + version "0.6.1" + resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" + integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== + +sourcemap-codec@^1.4.8: + version "1.4.8" + resolved "https://registry.yarnpkg.com/sourcemap-codec/-/sourcemap-codec-1.4.8.tgz#ea804bd94857402e6992d05a38ef1ae35a9ab4c4" + integrity sha512-9NykojV5Uih4lgo5So5dtw+f0JgJX30KCNI8gwhz2J9A15wD0Ml6tjHKwf6fTSa6fAdVBdZeNOs9eJ71qCk8vA== + +supports-preserve-symlinks-flag@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz#6eda4bd344a3c94aea376d4cc31bc77311039e09" + integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w== + +vite@^2.9.7: + version "2.9.14" + resolved "https://registry.yarnpkg.com/vite/-/vite-2.9.14.tgz#c438324c6594afd1050df3777da981dee988bb1b" + integrity sha512-P/UCjSpSMcE54r4mPak55hWAZPlyfS369svib/gpmz8/01L822lMPOJ/RYW6tLCe1RPvMvOsJ17erf55bKp4Hw== + dependencies: + esbuild "^0.14.27" + postcss "^8.4.13" + resolve "^1.22.0" + rollup "^2.59.0" + optionalDependencies: + fsevents "~2.3.2" + +vitepress@^1.0.0-alpha.4: + version "1.0.0-alpha.4" + resolved "https://registry.yarnpkg.com/vitepress/-/vitepress-1.0.0-alpha.4.tgz#2d9929e2cade3d98f57f61848c01968fb386cee0" + integrity sha512-bOAA4KW6vYGlkbcrPLZLTKWTgXVroObU+o9xj9EENyEl6yg26WWvfN7DGA4BftjdM5O8nR93Z5khPQ3W/tFE7Q== + dependencies: + "@docsearch/css" "^3.0.0" + "@docsearch/js" "^3.0.0" + "@vitejs/plugin-vue" "^2.3.2" + "@vue/devtools-api" "^6.1.4" + "@vueuse/core" "^8.5.0" + body-scroll-lock "^4.0.0-beta.0" + shiki "^0.10.1" + vite "^2.9.7" + vue "^3.2.33" + +vscode-oniguruma@^1.6.1: + version "1.6.2" + resolved "https://registry.yarnpkg.com/vscode-oniguruma/-/vscode-oniguruma-1.6.2.tgz#aeb9771a2f1dbfc9083c8a7fdd9cccaa3f386607" + integrity sha512-KH8+KKov5eS/9WhofZR8M8dMHWN2gTxjMsG4jd04YhpbPR91fUj7rYQ2/XjeHCJWbg7X++ApRIU9NUwM2vTvLA== + +vscode-textmate@5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/vscode-textmate/-/vscode-textmate-5.2.0.tgz#01f01760a391e8222fe4f33fbccbd1ad71aed74e" + integrity sha512-Uw5ooOQxRASHgu6C7GVvUxisKXfSgW4oFlO+aa+PAkgmH89O3CXxEEzNRNtHSqtXFTl0nAC1uYj0GMSH27uwtQ== + +vue-demi@*: + version "0.13.2" + resolved "https://registry.yarnpkg.com/vue-demi/-/vue-demi-0.13.2.tgz#f6081c2feb5b698549729a81683ce029b8da289e" + integrity sha512-41ukrclEbMddAyP7PvxMSYqnOSzPV6r7GNnyTSKSCNTaz19GehxmTiXyP9kwHSUv2+Dr6hHqiUiF7L1VAw2KdQ== + +vue@^3.2.33, vue@^3.2.37: + version "3.2.37" + resolved "https://registry.yarnpkg.com/vue/-/vue-3.2.37.tgz#da220ccb618d78579d25b06c7c21498ca4e5452e" + integrity sha512-bOKEZxrm8Eh+fveCqS1/NkG/n6aMidsI6hahas7pa0w/l7jkbssJVsRhVDs07IdDq7h9KHswZOgItnwJAgtVtQ== + dependencies: + "@vue/compiler-dom" "3.2.37" + "@vue/compiler-sfc" "3.2.37" + "@vue/runtime-dom" "3.2.37" + "@vue/server-renderer" "3.2.37" + "@vue/shared" "3.2.37"