26 lines
651 B
C++
26 lines
651 B
C++
//
|
|
// Created by dawsh on 6/16/24.
|
|
//
|
|
|
|
#include <cassert>
|
|
|
|
#include "include/jtest/jtest.hpp"
|
|
|
|
// Look into a different mechanism more similar to gtest wherein we have a TEST macro
|
|
// that declares and "registers" a test, and then inside our main block we call RUN_ALL_TESTS(argc, argv);
|
|
|
|
// Running into a suituation in which we can't catch assertations or "checks"
|
|
// Additionally, The tests appear to run out-of-order, but lambda functions shouldn't be asynchronous on their own?!!
|
|
int main()
|
|
{
|
|
|
|
TEST("Test1", []{
|
|
jtest::check(2+2 == 4);
|
|
});
|
|
|
|
TEST("Test2", [] {
|
|
jtest::check(2+2 == 5);
|
|
});
|
|
|
|
jtest::run_tests();
|
|
} |