Skip to content
Snippets Groups Projects

Fix tests when CMAKE_BUILD_TYPE is not set

Merged Marco Clemencic requested to merge 326-add-default-build-type into master

As agreed in #326 (closed), I modified the logic used to select the needed reference file variant so that an empty CMAKE_BUILD_TYPE picks up the reference file used for Debug builds (because it is most likely that the difference in the out put comes from the presence or not of -DNDEBUG on the compiler command line).

I also fixed a small bug in !1605 (merged): we were not recording correctly the actual reference file used for the test (done by means of a pytest fixture to avoid duplication).

While fixing the behavior of the tests I realized that a test was enabled for Debug builds, because it depends on NDEBUG. Now it is enabled for empty CMAKE_BUILD_TYPE too.

Closes #326 (closed)

Edited by Marco Clemencic

Merge request reports

Pipeline #8145139 passed

Pipeline passed for 73f8365e on 326-add-default-build-type

Approved by

Merged by Marco ClemencicMarco Clemencic 6 months ago (Sep 18, 2024 7:30am UTC)

Merge details

Pipeline #8158436 passed

Pipeline passed for 03984d2e on master

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
Please register or sign in to reply
Loading