From a7a5073ab7a118c2c862be558ff6a82d0531b4a7 Mon Sep 17 00:00:00 2001 From: Andreas Heinrich Date: Wed, 24 Sep 2025 13:49:08 +0200 Subject: [PATCH 1/7] tmp use branch Signed-off-by: Andreas Heinrich --- .github/workflows/build_and_test.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_and_test.yaml b/.github/workflows/build_and_test.yaml index 03fe268b83..752f695a7a 100644 --- a/.github/workflows/build_and_test.yaml +++ b/.github/workflows/build_and_test.yaml @@ -18,7 +18,7 @@ on: jobs: ci: name: Build, Lint and Test - uses: everest/everest-ci/.github/workflows/continuous_integration.yml@v1.4.6 + uses: everest/everest-ci/.github/workflows/continuous_integration.yml@chore-update-to-debian-trixie permissions: contents: read secrets: From 1bc82875e95afb4fe7057565c5afb9b0ec4ea218 Mon Sep 17 00:00:00 2001 From: Andreas Heinrich Date: Wed, 24 Sep 2025 13:53:29 +0200 Subject: [PATCH 2/7] minor fix Signed-off-by: Andreas Heinrich --- .github/workflows/build_and_test.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build_and_test.yaml b/.github/workflows/build_and_test.yaml index 752f695a7a..b1fc7aba01 100644 --- a/.github/workflows/build_and_test.yaml +++ b/.github/workflows/build_and_test.yaml @@ -18,7 +18,7 @@ on: jobs: ci: name: Build, Lint and Test - uses: everest/everest-ci/.github/workflows/continuous_integration.yml@chore-update-to-debian-trixie + uses: everest/everest-ci/.github/workflows/continuous_integration.yml@chore/update-to-debian-trixie permissions: contents: read secrets: @@ -30,6 +30,7 @@ jobs: do_not_run_coverage_badge_creation: true run_install_wheels: true run_integration_tests: true + build_kit_base_image_tag: chore-update-to-debian-trixie ocpp-tests: name: OCPP Tests needs: From b627f9637fa94716e835a215761b2e4514419934 Mon Sep 17 00:00:00 2001 From: Andreas Heinrich Date: Wed, 24 Sep 2025 14:31:55 +0200 Subject: [PATCH 3/7] add include Signed-off-by: Andreas Heinrich --- .../fusion_charger_lib/goose-lib/libs/goose/tests/sender.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modules/HardwareDrivers/PowerSupplies/Huawei_V100R023C10/fusion_charger_lib/goose-lib/libs/goose/tests/sender.cpp b/modules/HardwareDrivers/PowerSupplies/Huawei_V100R023C10/fusion_charger_lib/goose-lib/libs/goose/tests/sender.cpp index 0fd48c4638..a1bff6cea5 100644 --- a/modules/HardwareDrivers/PowerSupplies/Huawei_V100R023C10/fusion_charger_lib/goose-lib/libs/goose/tests/sender.cpp +++ b/modules/HardwareDrivers/PowerSupplies/Huawei_V100R023C10/fusion_charger_lib/goose-lib/libs/goose/tests/sender.cpp @@ -4,6 +4,8 @@ #include +#include + class DummyEthernetInterface : public goose_ethernet::EthernetInterfaceIntf { std::function send_callback; std::function()> receive_callback; From d12989d5cd0e074ff6cd5a7f5060e2750a3e17d7 Mon Sep 17 00:00:00 2001 From: Andreas Heinrich Date: Fri, 26 Sep 2025 00:54:08 +0200 Subject: [PATCH 4/7] Fix openssl tests, changed behaviour of function openssl::base64_decode Signed-off-by: Andreas Heinrich --- lib/everest/tls/tests/openssl_util_test.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/everest/tls/tests/openssl_util_test.cpp b/lib/everest/tls/tests/openssl_util_test.cpp index d64d479e1f..5bc7bab75f 100644 --- a/lib/everest/tls/tests/openssl_util_test.cpp +++ b/lib/everest/tls/tests/openssl_util_test.cpp @@ -254,26 +254,26 @@ TEST(openssl, base64EncodeNl) { } TEST(openssl, base64Decode) { - auto res = openssl::base64_decode(&iso_exi_a_hash_b64[0], sizeof(iso_exi_a_hash_b64)); + auto res = openssl::base64_decode(iso_exi_a_hash_b64, std::strlen(iso_exi_a_hash_b64)); ASSERT_EQ(res.size(), sizeof(iso_exi_a_hash)); EXPECT_EQ(std::memcmp(res.data(), &iso_exi_a_hash[0], res.size()), 0); - res = openssl::base64_decode(&iso_exi_sig_b64[0], sizeof(iso_exi_sig_b64)); + res = openssl::base64_decode(iso_exi_sig_b64, std::strlen(iso_exi_sig_b64)); ASSERT_EQ(res.size(), sizeof(iso_exi_sig)); EXPECT_EQ(std::memcmp(res.data(), &iso_exi_sig[0], res.size()), 0); std::array buffer{}; std::size_t buffer_len = buffer.size(); - EXPECT_TRUE(openssl::base64_decode(&iso_exi_a_hash_b64[0], sizeof(iso_exi_a_hash_b64), buffer.data(), buffer_len)); + EXPECT_TRUE(openssl::base64_decode(iso_exi_a_hash_b64, std::strlen(iso_exi_a_hash_b64), buffer.data(), buffer_len)); ASSERT_EQ(buffer_len, sizeof(iso_exi_a_hash)); EXPECT_EQ(std::memcmp(buffer.data(), &iso_exi_a_hash[0], buffer_len), 0); } TEST(openssl, base64DecodeNl) { - auto res = openssl::base64_decode(&iso_exi_a_hash_b64_nl[0], sizeof(iso_exi_a_hash_b64_nl)); + auto res = openssl::base64_decode(iso_exi_a_hash_b64_nl, std::strlen(iso_exi_a_hash_b64_nl)); ASSERT_EQ(res.size(), sizeof(iso_exi_a_hash)); EXPECT_EQ(std::memcmp(res.data(), &iso_exi_a_hash[0], res.size()), 0); - res = openssl::base64_decode(&iso_exi_sig_b64_nl[0], sizeof(iso_exi_sig_b64_nl)); + res = openssl::base64_decode(iso_exi_sig_b64_nl, std::strlen(iso_exi_sig_b64_nl)); ASSERT_EQ(res.size(), sizeof(iso_exi_sig)); EXPECT_EQ(std::memcmp(res.data(), &iso_exi_sig[0], res.size()), 0); @@ -281,7 +281,7 @@ TEST(openssl, base64DecodeNl) { std::size_t buffer_len = buffer.size(); EXPECT_TRUE( - openssl::base64_decode(&iso_exi_a_hash_b64_nl[0], sizeof(iso_exi_a_hash_b64_nl), buffer.data(), buffer_len)); + openssl::base64_decode(iso_exi_a_hash_b64_nl, std::strlen(iso_exi_a_hash_b64_nl), buffer.data(), buffer_len)); ASSERT_EQ(buffer_len, sizeof(iso_exi_a_hash)); EXPECT_EQ(std::memcmp(buffer.data(), &iso_exi_a_hash[0], buffer_len), 0); } From 1cc89d09b368da1774bd4393179cf1f107183685 Mon Sep 17 00:00:00 2001 From: Andreas Heinrich Date: Mon, 29 Sep 2025 11:57:07 +0200 Subject: [PATCH 5/7] run integration tests in venv Signed-off-by: Andreas Heinrich --- .../scripts/create_integration_image.sh | 16 ++++++++++++++++ .ci/build-kit/scripts/create_ocpp_tests_image.sh | 16 ++++++++++++++++ .ci/e2e/scripts/run_integration_tests.sh | 7 +++++++ .ci/e2e/scripts/run_ocpp_tests.sh | 7 +++++++ 4 files changed, 46 insertions(+) diff --git a/.ci/build-kit/scripts/create_integration_image.sh b/.ci/build-kit/scripts/create_integration_image.sh index 042f7f6e12..327fa00188 100755 --- a/.ci/build-kit/scripts/create_integration_image.sh +++ b/.ci/build-kit/scripts/create_integration_image.sh @@ -8,6 +8,22 @@ if [ $retVal -ne 0 ]; then exit $retVal fi +python3 -m venv "$EXT_MOUNT/venv" +retVal=$? + +if [ $retVal -ne 0 ]; then + echo "Failed to create virtual environment" + exit $retVal +fi + +source "$EXT_MOUNT/venv/bin/activate" +retVal=$? + +if [ $retVal -ne 0 ]; then + echo "Failed to activate virtual environment" + exit $retVal +fi + pip install --break-system-packages \ $EXT_MOUNT/wheels/everestpy-*.whl \ $EXT_MOUNT/wheels/everest_testing-*.whl \ diff --git a/.ci/build-kit/scripts/create_ocpp_tests_image.sh b/.ci/build-kit/scripts/create_ocpp_tests_image.sh index db2f25d44e..b256da5fb4 100755 --- a/.ci/build-kit/scripts/create_ocpp_tests_image.sh +++ b/.ci/build-kit/scripts/create_ocpp_tests_image.sh @@ -8,6 +8,22 @@ if [ $retVal -ne 0 ]; then exit $retVal fi +python3 -m venv "$EXT_MOUNT/venv" +retVal=$? + +if [ $retVal -ne 0 ]; then + echo "Failed to create virtual environment" + exit $retVal +fi + +source "$EXT_MOUNT/venv/bin/activate" +retVal=$? + +if [ $retVal -ne 0 ]; then + echo "Failed to activate virtual environment" + exit $retVal +fi + pip install --break-system-packages \ "$EXT_MOUNT"/wheels/everestpy-*.whl \ "$EXT_MOUNT"/wheels/everest_testing-*.whl \ diff --git a/.ci/e2e/scripts/run_integration_tests.sh b/.ci/e2e/scripts/run_integration_tests.sh index 6179499258..503680796c 100755 --- a/.ci/e2e/scripts/run_integration_tests.sh +++ b/.ci/e2e/scripts/run_integration_tests.sh @@ -1,5 +1,12 @@ #!/bin/sh +source "$EXT_MOUNT/venv/bin/activate" +retVal=$? +if [ $retVal -ne 0 ]; then + echo "Failed to activate virtual environment" + exit $retVal +fi + cd tests pytest \ -rA \ diff --git a/.ci/e2e/scripts/run_ocpp_tests.sh b/.ci/e2e/scripts/run_ocpp_tests.sh index 905626a7e7..024c296b56 100755 --- a/.ci/e2e/scripts/run_ocpp_tests.sh +++ b/.ci/e2e/scripts/run_ocpp_tests.sh @@ -1,5 +1,12 @@ #!/bin/sh +source "$EXT_MOUNT/venv/bin/activate" +retVal=$? +if [ $retVal -ne 0 ]; then + echo "Failed to activate virtual environment" + exit $retVal +fi + cd tests PARALLEL_TESTS=$(nproc) From 95e53c0739eaea0a0ebc3fc5bcf445047f612f25 Mon Sep 17 00:00:00 2001 From: Andreas Heinrich Date: Mon, 29 Sep 2025 14:10:03 +0200 Subject: [PATCH 6/7] switch to bash Signed-off-by: Andreas Heinrich --- .ci/build-kit/scripts/create_integration_image.sh | 2 +- .ci/build-kit/scripts/create_ocpp_tests_image.sh | 2 +- .ci/e2e/scripts/run_integration_tests.sh | 2 +- .ci/e2e/scripts/run_ocpp_tests.sh | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.ci/build-kit/scripts/create_integration_image.sh b/.ci/build-kit/scripts/create_integration_image.sh index 327fa00188..e4c678abab 100755 --- a/.ci/build-kit/scripts/create_integration_image.sh +++ b/.ci/build-kit/scripts/create_integration_image.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash rsync -a "$EXT_MOUNT/source/tests" ./ retVal=$? diff --git a/.ci/build-kit/scripts/create_ocpp_tests_image.sh b/.ci/build-kit/scripts/create_ocpp_tests_image.sh index b256da5fb4..c62d0214e2 100755 --- a/.ci/build-kit/scripts/create_ocpp_tests_image.sh +++ b/.ci/build-kit/scripts/create_ocpp_tests_image.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash rsync -a "$EXT_MOUNT/source/tests" ./ retVal=$? diff --git a/.ci/e2e/scripts/run_integration_tests.sh b/.ci/e2e/scripts/run_integration_tests.sh index 503680796c..5d9c613f34 100755 --- a/.ci/e2e/scripts/run_integration_tests.sh +++ b/.ci/e2e/scripts/run_integration_tests.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash source "$EXT_MOUNT/venv/bin/activate" retVal=$? diff --git a/.ci/e2e/scripts/run_ocpp_tests.sh b/.ci/e2e/scripts/run_ocpp_tests.sh index 024c296b56..76e4519b17 100755 --- a/.ci/e2e/scripts/run_ocpp_tests.sh +++ b/.ci/e2e/scripts/run_ocpp_tests.sh @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash source "$EXT_MOUNT/venv/bin/activate" retVal=$? From 3150c93f700cd6b62b743d8d035d3e15f9bda0c8 Mon Sep 17 00:00:00 2001 From: Andreas Heinrich Date: Mon, 29 Sep 2025 16:17:43 +0200 Subject: [PATCH 7/7] add --system-site-packages flag Signed-off-by: Andreas Heinrich --- .ci/build-kit/scripts/create_integration_image.sh | 2 +- .ci/build-kit/scripts/create_ocpp_tests_image.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.ci/build-kit/scripts/create_integration_image.sh b/.ci/build-kit/scripts/create_integration_image.sh index e4c678abab..cdddfcf454 100755 --- a/.ci/build-kit/scripts/create_integration_image.sh +++ b/.ci/build-kit/scripts/create_integration_image.sh @@ -8,7 +8,7 @@ if [ $retVal -ne 0 ]; then exit $retVal fi -python3 -m venv "$EXT_MOUNT/venv" +python3 -m venv "$EXT_MOUNT/venv" --system-site-packages retVal=$? if [ $retVal -ne 0 ]; then diff --git a/.ci/build-kit/scripts/create_ocpp_tests_image.sh b/.ci/build-kit/scripts/create_ocpp_tests_image.sh index c62d0214e2..e663d99d85 100755 --- a/.ci/build-kit/scripts/create_ocpp_tests_image.sh +++ b/.ci/build-kit/scripts/create_ocpp_tests_image.sh @@ -8,7 +8,7 @@ if [ $retVal -ne 0 ]; then exit $retVal fi -python3 -m venv "$EXT_MOUNT/venv" +python3 -m venv "$EXT_MOUNT/venv" --system-site-packages retVal=$? if [ $retVal -ne 0 ]; then