Every other port in the fleet states its image size and is held to it; this one stated none, so a library advance could move `clock` and no check would say a word - which is exactly what the size claim was built after. The two numbers are what the presets build today, byte-identical across generated and reflect, and the README now says both. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
18 lines
684 B
CMake
18 lines
684 B
CMake
libavr_format_test()
|
|
|
|
# The example's size is stated in the README, per chip, and a library advance
|
|
# that moves it silently is what this catches.
|
|
if(LIBAVR_MCU STREQUAL "atmega328p")
|
|
libavr_size_claim_test(clock 1480)
|
|
elseif(LIBAVR_MCU STREQUAL "attiny85")
|
|
libavr_size_claim_test(clock 1238)
|
|
endif()
|
|
|
|
# The battery is a compile: a static_assert that fails is the failure. It is a
|
|
# target rather than only a ctest so a plain build catches a regression too.
|
|
add_library(consteval_tests OBJECT consteval.cpp)
|
|
target_link_libraries(consteval_tests PRIVATE ds3231)
|
|
|
|
add_test(NAME ds3231.consteval
|
|
COMMAND ${CMAKE_COMMAND} --build ${CMAKE_BINARY_DIR} --target consteval_tests)
|