General Purpose library for Freestanding C++ and POSIX systems
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
692 B

  1. #include "test_scaffold.h"
  2. #include "meta_test.cpp"
  3. #include "shared_fd.cpp"
  4. #include "rc6_generic.cpp"
  5. #include "gp_test.cpp"
  6. #include "bloomfilter.cpp"
  7. #include "quotient_filter.cpp"
  8. #include <iostream>
  9. int main()
  10. {
  11. uint failed = 0;
  12. uint runned = 0;
  13. for(auto& test : tests)
  14. {
  15. ++runned;
  16. int value;
  17. try{
  18. value = test->run();
  19. if(value)
  20. {
  21. std::cout << std::dec << test->name << " failed with "<< value << std::endl;
  22. }
  23. } catch (...) {
  24. std::cout << test->name << " failed with an exception" << std::endl;
  25. value = -1;
  26. }
  27. failed += (value != 0);
  28. }
  29. std::cout << std::dec << "Runned "<<runned<<" tests with "<<failed<<" failures" << std::endl;
  30. return 0;
  31. }