rusefi/unit_tests
Matthew Kennedy 084ad25784 unnecessary functions
only:uaefi
2025-01-09 13:35:20 -05:00
..
chibios-mock unit_test: ThreadReference mock 2024-03-11 16:54:58 -04:00
googletest@c231e6f5b1 fresh googletest 2024-03-15 21:32:42 -06:00
test-framework technical debt: NT -> US -> NT in unit test scheduler #7245 2025-01-02 23:01:35 -05:00
test_basic_math only: wow, all of this was dead code 2024-07-03 10:16:24 -04:00
test_results Create readme.md 2024-12-29 21:06:34 -05:00
tests unnecessary functions 2025-01-09 13:35:20 -05:00
.cproject dead warningEnabled global variable (#5636) 2023-10-24 18:55:29 -04:00
.gitignore unit_tests "logic analyzer" moved to dedicated folder 2024-12-27 15:32:17 -04:00
.project
Makefile unit tests to write MS logs #7222 2024-12-27 22:38:52 -05:00
adc_inputs.h adc: fix unit tests 2024-05-05 13:26:24 -04:00
boards.cpp adc: try to clean naming mess: getVoltageDivided() rename to adcGetScaledVoltage() 2024-12-09 07:43:43 -05:00
boards.h adc: try to clean naming mess: getAdcValue() rename to adcGetRawValue() 2024-12-09 07:43:43 -05:00
ci_gcov.sh
clean_compile.bat
clean_compile.sh
efifeatures.h SD card is missing "ETB average duty0" field fix #6720 2024-12-29 09:02:15 -05:00
global.h time for VCS_VERSION to go 2024-05-29 18:10:01 -04:00
global_mocks.cpp https://sourceware.org/bugzilla/show_bug.cgi?id=9687 Weak symbols not working on mingw32 2024-08-03 12:24:06 -04:00
gmock-all.cpp
gtest-all.cpp
logicdata.cpp unit_tests "logic analyzer" style output #6403 2024-12-24 22:39:46 -05:00
logicdata.h unit_tests "logic analyzer" style output #6403 2024-12-24 22:39:46 -05:00
main.cpp Usability: critical error in case of unneeded second channel #6419 2024-04-26 22:18:01 -04:00
mocks.cpp only:testability 2024-09-18 00:33:15 -04:00
mocks.h lua pedal is a thing 2024-11-11 20:57:12 -05:00
readme.md enhance instruction for running single test 2024-04-25 13:10:34 -04:00
rules.mk fix unit tests cleaning 2024-02-24 19:37:15 -05:00
run_clean_gcov.sh
run_logicdata_sandbox.bat
run_sharded_tests.sh
test.mk only: renaming .cpp 2024-04-30 16:15:13 -04:00
triggers.txt Trigger wheel definitions 2024-11-04 15:37:57 +00:00
unit_test_rules.mk compile coverage 2025-01-08 19:34:07 -05:00

readme.md

See https://github.com/rusefi/rusefi/wiki/Dev-Quality-Control

TL, DR: just follow tests folder as examples. gcc/makefile/gtest

  1. Run 'make' to build desktop binary.
  2. Execute rusefi_test binary on your PC/Mac, it's expected to say SUCCESS and not fail :) Googletest will also print results summary.
  3. To run only one test use command line like build/rusefi_test --gtest_filter=*TEST_NAME* uncomment and modify main.cpp line ::testing::GTEST_FLAG(filter)

In this folder we have rusEFI unit tests using https://github.com/google/googletest

Unit tests are not aware of ChibiOS or ARM or else, they are just plain C/C++ which you build for your desktop, not your MCU.

Code Coverage Report

See also https://github.com/rusefi/rusefi/wiki/Build-Server-and-Automation

Triggers Images

Trigger images generation is still a two-step manual process:

Step 1: Invoke unit_tests. One of the unit_tests artifacts is triggers.txt

Step 2: Once we have triggers.txt updated by unit_tests we can invoke firmware/gen_trigger_images.bat in order to generate actual trigger images.