From e487f19260cc356f7179e0edbc6395a229b04320 Mon Sep 17 00:00:00 2001 From: jean-pierre charras Date: Sun, 26 Jan 2025 11:47:18 +0100 Subject: [PATCH] QA api test: ensure the "C" locale is used in tests. Fix also a compatibility with current code in drc_proto.cpp --- qa/tests/api/test_api_module.cpp | 5 ++++- qa/tools/drc_proto/drc_proto.cpp | 3 ++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/qa/tests/api/test_api_module.cpp b/qa/tests/api/test_api_module.cpp index 3375a5e26e..10b48eadd1 100644 --- a/qa/tests/api/test_api_module.cpp +++ b/qa/tests/api/test_api_module.cpp @@ -23,7 +23,7 @@ #include #include #include - +#include bool init_unit_test() { @@ -33,6 +33,9 @@ bool init_unit_test() wxApp::SetInstance( new wxAppConsole ); + // Ensure the "C" locale is used + LOCALE_IO dummy; + bool ok = wxInitialize( boost::unit_test::framework::master_test_suite().argc, boost::unit_test::framework::master_test_suite().argv ); diff --git a/qa/tools/drc_proto/drc_proto.cpp b/qa/tools/drc_proto/drc_proto.cpp index 8763602613..66dd8b7cb5 100644 --- a/qa/tools/drc_proto/drc_proto.cpp +++ b/qa/tools/drc_proto/drc_proto.cpp @@ -114,7 +114,8 @@ int runDRCProto( PROJECT_CONTEXT project, std::shared_ptr a drcEngine->SetProgressReporter( new CONSOLE_PROGRESS_REPORTER ( &consoleLog ) ); drcEngine->SetViolationHandler( - [&]( const std::shared_ptr& aItem, VECTOR2I aPos, int aLayer ) + [&]( const std::shared_ptr& aItem, VECTOR2I aPos, + int aLayer,DRC_CUSTOM_MARKER_HANDLER* aCustomHandler ) { // fixme } );