You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

31 lines
607 B

  1. #include "gtest/gtest.h"
  2. extern "C" {
  3. #include "stdio.h"
  4. #include "debug.h"
  5. int8_t sendchar(uint8_t c) {
  6. fprintf(stderr, "%c", c);
  7. return 0;
  8. }
  9. __attribute__((weak)) debug_config_t debug_config = {0};
  10. void init_logging(void) {
  11. print_set_sendchar(sendchar);
  12. // Customise these values to desired behaviour
  13. // debug_enable = true;
  14. // debug_matrix = true;
  15. // debug_keyboard = true;
  16. // debug_mouse = true;
  17. debug_config.raw = 0xFF;
  18. }
  19. }
  20. int main(int argc, char **argv) {
  21. ::testing::InitGoogleTest(&argc, argv);
  22. init_logging();
  23. return RUN_ALL_TESTS();
  24. }