tap.hpp 416 B

123456789101112131415161718192021222324252627
  1. #include <string>
  2. class Tap {
  3. public:
  4. class Test;
  5. Tap();
  6. ~Tap();
  7. private:
  8. static int total;
  9. static int errored;
  10. static bool started;
  11. };
  12. class Tap::Test {
  13. public:
  14. Test(const std::string &name);
  15. ~Test();
  16. void ok(bool status, const std::string &message);
  17. void fail(const std::string &message);
  18. void end();
  19. private:
  20. bool failed = false;
  21. bool finished = false;
  22. };