From 69536d9d4f92f25a54ad9a7e55942b068697f0bf Mon Sep 17 00:00:00 2001 From: ruki Date: Thu, 29 Aug 2024 13:08:03 +0800 Subject: [PATCH] Auto-update faker-cxx to v3.0.0 (#5079) * Update faker-cxx to v3.0.0 * fix test header file name --------- Co-authored-by: star9029 --- packages/f/faker-cxx/xmake.lua | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/packages/f/faker-cxx/xmake.lua b/packages/f/faker-cxx/xmake.lua index df5cc5f8c..de37830fc 100644 --- a/packages/f/faker-cxx/xmake.lua +++ b/packages/f/faker-cxx/xmake.lua @@ -6,6 +6,7 @@ package("faker-cxx") add_urls("https://github.com/cieslarmichal/faker-cxx/archive/refs/tags/$(version).tar.gz", "https://github.com/cieslarmichal/faker-cxx.git") + add_versions("v3.0.0", "63d6846376593e05da690136cabe8e7bf42ddcdd4edad3ae9b48696f86d80468") add_versions("v2.0.0", "8a7f5441f4453af868444675878a2d9a74918c1595caa65d537d3ea327e46a49") add_deps("cmake") @@ -41,9 +42,15 @@ package("faker-cxx") end) on_test(function (package) + local includes = "faker-cxx/string.h" + local version = package:version() + if version and version:lt("3.0.0") then + includes = "faker-cxx/String.h" + end + assert(package:check_cxxsnippets({test = [[ void test() { const auto id = faker::string::uuid(); } - ]]}, {configs = {languages = "c++20"}, includes = "faker-cxx/String.h"})) + ]]}, {configs = {languages = "c++20"}, includes = includes})) end)