EVerest / libevse-security

Apache License 2.0
7 stars 5 forks source link

Make test target name unique. #28

Closed gberardi-pillar closed 5 months ago

gberardi-pillar commented 6 months ago

everest-core cannot build with tests (BUILD_TESTING=ON) due to submodules having generic names that collide when CMake runs.

This change makes the test target for libevse-security unique by naming it after the repo, a pattern that can be followed for all repos.

NOTE: This change does not enable automated builds and tests, as there are other PRs to handle that work. I will also point out that when I run the tests manually, 17 out of 26 tests fail.

ALSO NOTE: I changed the flag from BUILD_TESTING_EVSE_SECURITY to BUILD_TESTING, since that variable gets used by CTest and is needed to allow the make test target to work.

I also used the Modern CMake pattern of enabling tests only if the project is the main project (not a child of a parent project) or if it is explicitly specified with cmake -Deverest-evse_security_BUILD_TESTING=ON to allow flexibility.

gberardi-pillar commented 6 months ago

@shankari Here's a minor change to review.

gberardi-pillar commented 6 months ago

@valentin-dimov Since you have contributed the most to this repo, would you be able to look at this PR?

Dominik-K commented 6 months ago

Let's discuss in general at