Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //////////
- // test_dummy.hpp
- //
- #include "testcase.hpp"
- testcase(Dummy) {
- int a = 0;
- on_setup {
- a = 15;
- }
- unittest(arithmetic) {
- assert_equal(20, a + 5);
- a = 70;
- ok();
- }
- unittest(fail) {
- assert_equal(a, 70);
- ok();
- }
- on_teardown {
- }
- };
- int main(int argc, char *argv[]) {
- return test_main(argc, argv);
- }
- /*
- microtest version 0.1
- -----------------------------------------
- Running the test case "Dummy"
- Test case contains 2 tests
- .F
- 1 succeeded, 1 failed, 0 flagged, 0 skipped.
- Test case 'fail' failed:
- Assertion failure: a != 70 (15 != 70)
- */
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement