Read-only mirrors. Development, issues and pull requests are on GitHub.

summaryrefslogtreecommitdiffhomepage
path: root/examples
diff options
context:
space:
mode:
authorLeitwolf112026-11-01 00:25:59 +0300
committerLeitwolf112026-11-01 00:25:59 +0300
commitff1da91edffa9ee887e9fe737fcd87ec540dfa60 (patch)
tree25841e888932ebac3a51c4b59f77cea5a87ae5bd /examples
parent42c68725c816963ec6529dd635d5aaaac23b1c05 (diff)
downloadcatch3-chore/cpp17-descriptions.tar.gz
Say C++17 everywhere the project describes itselfchore/cpp17-descriptions
The move to C++17 left a trail of older claims. The Runner's own .clang-format still said c++20; the result is byte for byte the same under either value. Premake and Xmake still compiled the library as C++20 and the main library as C++14, which meant their CI jobs were not testing the language the project promises. Both now use C++17 for every target. The rest is text: the Meson pkg-config description claimed C++14, comments in the CMake and Meson files explained requirements that no longer exist, .clang-tidy gave C++14 as the reason for two exclusions, issue templates asked for C++20 samples, and the example headers named -std=c++14 and catch2-with-main. The release notes and the migration guide state the C++17 minimum. Doxygen's brief called the project "Catch2's test API", which presents it as Catch2. Meson declared only BSL-1.0; it now names both licenses of the tree. The amalgamated files are regenerated.
Diffstat (limited to 'examples')
-rw-r--r--examples/010-TestCase.cpp2
-rw-r--r--examples/020-TestCase-1.cpp4
-rw-r--r--examples/030-Asn-Require-Check.cpp2
-rw-r--r--examples/100-Fix-Section.cpp2
-rw-r--r--examples/110-Fix-ClassFixture.cpp4
-rw-r--r--examples/120-Bdd-ScenarioGivenWhenThen.cpp2
-rw-r--r--examples/210-Evt-EventListeners.cpp2
7 files changed, 9 insertions, 9 deletions
diff --git a/examples/010-TestCase.cpp b/examples/010-TestCase.cpp
index 5eb982c8..d4c42a48 100644
--- a/examples/010-TestCase.cpp
+++ b/examples/010-TestCase.cpp
@@ -27,7 +27,7 @@ TEST_CASE( "Factorials of 1 and higher are computed (pass)", "[single-file]" ) {
}
// Compile & run:
-// - g++ -std=c++14 -Wall -I$(CATCH_SINGLE_INCLUDE) -o 010-TestCase 010-TestCase.cpp && 010-TestCase --success
+// - g++ -std=c++17 -Wall -I$(CATCH_SINGLE_INCLUDE) -o 010-TestCase 010-TestCase.cpp && 010-TestCase --success
// - cl -EHsc -I%CATCH_SINGLE_INCLUDE% 010-TestCase.cpp && 010-TestCase --success
// Expected compact output (all assertions):
diff --git a/examples/020-TestCase-1.cpp b/examples/020-TestCase-1.cpp
index 86de07a9..1acdc7a0 100644
--- a/examples/020-TestCase-1.cpp
+++ b/examples/020-TestCase-1.cpp
@@ -18,8 +18,8 @@ TEST_CASE( "1: All test cases reside in other .cpp files (empty)", "[multi-file:
// Here just to show there are two source files via option --list-tests.
// Compile & run:
-// - g++ -std=c++14 -Wall -I$(CATCH_SINGLE_INCLUDE) -c 020-TestCase-1.cpp
-// - g++ -std=c++14 -Wall -I$(CATCH_SINGLE_INCLUDE) -o 020-TestCase TestCase-1.o 020-TestCase-2.cpp && 020-TestCase --success
+// - g++ -std=c++17 -Wall -I$(CATCH_SINGLE_INCLUDE) -c 020-TestCase-1.cpp
+// - g++ -std=c++17 -Wall -I$(CATCH_SINGLE_INCLUDE) -o 020-TestCase TestCase-1.o 020-TestCase-2.cpp && 020-TestCase --success
//
// - cl -EHsc -I%CATCH_SINGLE_INCLUDE% -c 020-TestCase-1.cpp
// - cl -EHsc -I%CATCH_SINGLE_INCLUDE% -Fe020-TestCase.exe 020-TestCase-1.obj 020-TestCase-2.cpp && 020-TestCase --success
diff --git a/examples/030-Asn-Require-Check.cpp b/examples/030-Asn-Require-Check.cpp
index ed6ad752..416db4bc 100644
--- a/examples/030-Asn-Require-Check.cpp
+++ b/examples/030-Asn-Require-Check.cpp
@@ -61,7 +61,7 @@ TEST_CASE( "Assert that something is false (continue after failure)", "[check-fa
}
// Compile & run:
-// - g++ -std=c++14 -Wall -I$(CATCH_SINGLE_INCLUDE) -o 030-Asn-Require-Check 030-Asn-Require-Check.cpp && 030-Asn-Require-Check --success
+// - g++ -std=c++17 -Wall -I$(CATCH_SINGLE_INCLUDE) -o 030-Asn-Require-Check 030-Asn-Require-Check.cpp && 030-Asn-Require-Check --success
// - cl -EHsc -I%CATCH_SINGLE_INCLUDE% 030-Asn-Require-Check.cpp && 030-Asn-Require-Check --success
// Expected compact output (all assertions):
diff --git a/examples/100-Fix-Section.cpp b/examples/100-Fix-Section.cpp
index d1e4cdbc..b095d78b 100644
--- a/examples/100-Fix-Section.cpp
+++ b/examples/100-Fix-Section.cpp
@@ -53,7 +53,7 @@ TEST_CASE( "vectors can be sized and resized", "[vector]" ) {
}
// Compile & run:
-// - g++ -std=c++14 -Wall -I$(CATCH_SINGLE_INCLUDE) -o 100-Fix-Section 100-Fix-Section.cpp && 100-Fix-Section --success
+// - g++ -std=c++17 -Wall -I$(CATCH_SINGLE_INCLUDE) -o 100-Fix-Section 100-Fix-Section.cpp && 100-Fix-Section --success
// - cl -EHsc -I%CATCH_SINGLE_INCLUDE% 100-Fix-Section.cpp && 100-Fix-Section --success
// Expected compact output (all assertions):
diff --git a/examples/110-Fix-ClassFixture.cpp b/examples/110-Fix-ClassFixture.cpp
index 1b3f053f..f988f676 100644
--- a/examples/110-Fix-ClassFixture.cpp
+++ b/examples/110-Fix-ClassFixture.cpp
@@ -60,11 +60,11 @@ TEST_CASE_METHOD( UniqueTestsFixture, "Create Employee/Normal", "[create]" ) {
}
// Compile & run:
-// - g++ -std=c++14 -Wall -I$(CATCH_SINGLE_INCLUDE) -o 110-Fix-ClassFixture 110-Fix-ClassFixture.cpp && 110-Fix-ClassFixture --success
+// - g++ -std=c++17 -Wall -I$(CATCH_SINGLE_INCLUDE) -o 110-Fix-ClassFixture 110-Fix-ClassFixture.cpp && 110-Fix-ClassFixture --success
// - cl -EHsc -I%CATCH_SINGLE_INCLUDE% 110-Fix-ClassFixture.cpp && 110-Fix-ClassFixture --success
//
// Compile with pkg-config:
-// - g++ -std=c++14 -Wall $(pkg-config catch2-with-main --cflags) -o 110-Fix-ClassFixture 110-Fix-ClassFixture.cpp $(pkg-config catch2-with-main --libs)
+// - g++ -std=c++17 -Wall $(pkg-config catch3-with-main --cflags) -o 110-Fix-ClassFixture 110-Fix-ClassFixture.cpp $(pkg-config catch3-with-main --libs)
// Expected compact output (all assertions):
//
diff --git a/examples/120-Bdd-ScenarioGivenWhenThen.cpp b/examples/120-Bdd-ScenarioGivenWhenThen.cpp
index b3edcd8c..1446393c 100644
--- a/examples/120-Bdd-ScenarioGivenWhenThen.cpp
+++ b/examples/120-Bdd-ScenarioGivenWhenThen.cpp
@@ -56,7 +56,7 @@ SCENARIO( "vectors can be sized and resized", "[vector]" ) {
}
// Compile & run:
-// - g++ -std=c++14 -Wall -I$(CATCH_SINGLE_INCLUDE) -o 120-Bdd-ScenarioGivenWhenThen 120-Bdd-ScenarioGivenWhenThen.cpp && 120-Bdd-ScenarioGivenWhenThen --success
+// - g++ -std=c++17 -Wall -I$(CATCH_SINGLE_INCLUDE) -o 120-Bdd-ScenarioGivenWhenThen 120-Bdd-ScenarioGivenWhenThen.cpp && 120-Bdd-ScenarioGivenWhenThen --success
// - cl -EHsc -I%CATCH_SINGLE_INCLUDE% 120-Bdd-ScenarioGivenWhenThen.cpp && 120-Bdd-ScenarioGivenWhenThen --success
// Expected compact output (all assertions):
diff --git a/examples/210-Evt-EventListeners.cpp b/examples/210-Evt-EventListeners.cpp
index 48ccce20..5c09d283 100644
--- a/examples/210-Evt-EventListeners.cpp
+++ b/examples/210-Evt-EventListeners.cpp
@@ -419,7 +419,7 @@ TEST_CASE_METHOD( Fixture, "3: Testcase with class-based fixture", "[tag-C][tag-
}
// Compile & run:
-// - g++ -std=c++14 -Wall -I$(CATCH_SINGLE_INCLUDE) -o 210-Evt-EventListeners 210-Evt-EventListeners.cpp && 210-Evt-EventListeners --success
+// - g++ -std=c++17 -Wall -I$(CATCH_SINGLE_INCLUDE) -o 210-Evt-EventListeners 210-Evt-EventListeners.cpp && 210-Evt-EventListeners --success
// - cl -EHsc -I%CATCH_SINGLE_INCLUDE% 210-Evt-EventListeners.cpp && 210-Evt-EventListeners --success
// Expected compact output (all assertions):