Skip to content

Commit 961d0e9

Browse files
authored
Add Clang 22 CI build (#326)
* Add Clang 22 CI build * Update doctest 2.4.12 * Update doctest to v2.5.0 * Fix MacOS build failure
1 parent 222fa8b commit 961d0e9

4 files changed

Lines changed: 9 additions & 8 deletions

File tree

.github/workflows/ci.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ jobs:
3434
strategy:
3535
matrix:
3636
build_config:
37+
- { version: 22 }
3738
- { version: 21 }
3839
- { version: 20 }
3940
- { version: 19 }

conanfile.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[requires]
2-
doctest/2.4.11
2+
doctest/2.4.12
33

44
[generators]
55
CMakeToolchain

script/ci.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ fi
2828
# Function to install doctest
2929
_install_doctest() {
3030
cd "$REPO_DIR"
31-
git clone --depth=1 --branch=v2.4.12 https://github.com/doctest/doctest
31+
git clone --depth=1 --branch=v2.5.0 https://github.com/doctest/doctest
3232
cd doctest && mkdir -p build && cd build
3333
cmake .. -DDOCTEST_WITH_TESTS=OFF -DDOCTEST_WITH_MAIN_IN_STATIC_LIB=OFF -DCMAKE_INSTALL_PREFIX=$INSTALL_PREFIX
3434
cmake --build . --config Release --target install

test/udemy_course_test.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -291,18 +291,18 @@ TEST_CASE("udemy_course_test - Function_composition")
291291
}
292292

293293
namespace Programming_challenge_an_SQL_analogy {
294-
struct user {
294+
struct User {
295295
std::string name;
296296
std::string country;
297297
std::size_t visits;
298298
};
299299

300-
std::string get_country(const user& u)
300+
std::string get_country(const User& u)
301301
{
302302
return u.country;
303303
}
304304

305-
std::size_t get_visits(const user& u)
305+
std::size_t get_visits(const User& u)
306306
{
307307
return u.visits;
308308
}
@@ -312,15 +312,15 @@ TEST_CASE("udemy_course_test - Programming_challenge_an_SQL_analogy")
312312
{
313313
using namespace Programming_challenge_an_SQL_analogy;
314314

315-
const std::vector<user> users = {
315+
const std::vector<User> users = {
316316
{ "Nicole", "GER", 2 },
317317
{ "Justin", "USA", 1 },
318318
{ "Rachel", "USA", 5 },
319319
{ "Robert", "USA", 6 },
320320
{ "Stefan", "GER", 4 }
321321
};
322322

323-
const auto visit_sum = [](const std::vector<user>& xs) -> std::size_t {
323+
const auto visit_sum = [](const std::vector<User>& xs) -> std::size_t {
324324
return fplus::fwd::apply(xs, fplus::fwd::transform(get_visits), fplus::fwd::sum());
325325
};
326326

@@ -489,4 +489,4 @@ TEST_CASE("udemy_course_test - OOP_Design_patterns_vanishing")
489489

490490
REQUIRE_EQ(a, 16);
491491
REQUIRE_EQ(b, 25);
492-
}
492+
}

0 commit comments

Comments
 (0)