onqtam | 2c100d6 | 2017-04-16 22:47:28 +0300 | [diff] [blame] | 1 | [doctest] run with "--help" for options |
onqtam | 35c14cd | 2017-04-24 12:54:03 +0300 | [diff] [blame] | 2 | =============================================================================== |
onqtam | 1655b24 | 2018-05-10 15:29:21 +0300 | [diff] [blame] | 3 | stringification.cpp(0): |
Salvage | 6545bdc | 2022-01-13 00:14:21 +0100 | [diff] [blame] | 4 | TEST CASE: no headers |
| 5 | |
Salvage | ec2adbd | 2022-01-18 02:57:06 +0100 | [diff] [blame] | 6 | stringification.cpp(0): MESSAGE: 1as |
Salvage | 6545bdc | 2022-01-13 00:14:21 +0100 | [diff] [blame] | 7 | |
Salvage | 4bc7a75 | 2022-01-18 05:35:57 +0100 | [diff] [blame] | 8 | stringification.cpp(0): ERROR: CHECK( chs == nullptr ) is NOT correct! |
| 9 | values: CHECK( 1as == nullptr ) |
Salvage | 6545bdc | 2022-01-13 00:14:21 +0100 | [diff] [blame] | 10 | |
| 11 | stringification.cpp(0): MESSAGE: 1as |
| 12 | |
| 13 | stringification.cpp(0): ERROR: CHECK( "1as" == nullptr ) is NOT correct! |
Salvage | 4bc7a75 | 2022-01-18 05:35:57 +0100 | [diff] [blame] | 14 | values: CHECK( 1as == nullptr ) |
Salvage | 6545bdc | 2022-01-13 00:14:21 +0100 | [diff] [blame] | 15 | |
Salvage | 4bc7a75 | 2022-01-18 05:35:57 +0100 | [diff] [blame] | 16 | stringification.cpp(0): MESSAGE: [0, 1, 1, 2, 3, 5, 8, 13] |
Salvage | 6545bdc | 2022-01-13 00:14:21 +0100 | [diff] [blame] | 17 | |
| 18 | stringification.cpp(0): ERROR: CHECK( ints == nullptr ) is NOT correct! |
Salvage | 4bc7a75 | 2022-01-18 05:35:57 +0100 | [diff] [blame] | 19 | values: CHECK( [0, 1, 1, 2, 3, 5, 8, 13] == nullptr ) |
Salvage | 7be3b87 | 2022-01-13 05:08:34 +0100 | [diff] [blame] | 20 | |
Salvage | 996ef32 | 2022-01-18 05:45:52 +0100 | [diff] [blame] | 21 | stringification.cpp(0): MESSAGE: nullptr |
| 22 | |
| 23 | stringification.cpp(0): ERROR: CHECK( cnptr != nullptr ) is NOT correct! |
| 24 | values: CHECK( nullptr != nullptr ) |
| 25 | |
Salvage | 7be3b87 | 2022-01-13 05:08:34 +0100 | [diff] [blame] | 26 | stringification.cpp(0): MESSAGE: 0 |
| 27 | |
| 28 | stringification.cpp(0): ERROR: CHECK( A == C ) is NOT correct! |
| 29 | values: CHECK( 0 == 100 ) |
| 30 | |
Salvage | 6545bdc | 2022-01-13 00:14:21 +0100 | [diff] [blame] | 31 | =============================================================================== |
| 32 | stringification.cpp(0): |
onqtam | 35c14cd | 2017-04-24 12:54:03 +0300 | [diff] [blame] | 33 | TEST CASE: all asserts should fail and show how the objects get stringified |
onqtam | 2c100d6 | 2017-04-16 22:47:28 +0300 | [diff] [blame] | 34 | |
Salvage | 6545bdc | 2022-01-13 00:14:21 +0100 | [diff] [blame] | 35 | stringification.cpp(0): MESSAGE: Foo{} |
| 36 | |
onqtam | 1655b24 | 2018-05-10 15:29:21 +0300 | [diff] [blame] | 37 | stringification.cpp(0): ERROR: CHECK( f1 == f2 ) is NOT correct! |
| 38 | values: CHECK( Foo{} == Foo{} ) |
onqtam | 2c100d6 | 2017-04-16 22:47:28 +0300 | [diff] [blame] | 39 | |
Salvage | 6545bdc | 2022-01-13 00:14:21 +0100 | [diff] [blame] | 40 | stringification.cpp(0): MESSAGE: omg |
| 41 | |
onqtam | 367098b | 2021-12-15 15:15:06 +0200 | [diff] [blame] | 42 | stringification.cpp(0): ERROR: CHECK( dummy == "tralala" ) is NOT correct! |
onqtam | 1655b24 | 2018-05-10 15:29:21 +0300 | [diff] [blame] | 43 | values: CHECK( omg == tralala ) |
onqtam | 2c100d6 | 2017-04-16 22:47:28 +0300 | [diff] [blame] | 44 | |
onqtam | 367098b | 2021-12-15 15:15:06 +0200 | [diff] [blame] | 45 | stringification.cpp(0): ERROR: CHECK( "tralala" == dummy ) is NOT correct! |
| 46 | values: CHECK( tralala == omg ) |
| 47 | |
Salvage | 6545bdc | 2022-01-13 00:14:21 +0100 | [diff] [blame] | 48 | stringification.cpp(0): MESSAGE: [1, 2, 3] |
| 49 | |
onqtam | 1655b24 | 2018-05-10 15:29:21 +0300 | [diff] [blame] | 50 | stringification.cpp(0): ERROR: CHECK( vec1 == vec2 ) is NOT correct! |
| 51 | values: CHECK( [1, 2, 3] == [1, 2, 4] ) |
onqtam | 2c100d6 | 2017-04-16 22:47:28 +0300 | [diff] [blame] | 52 | |
Salvage | 6545bdc | 2022-01-13 00:14:21 +0100 | [diff] [blame] | 53 | stringification.cpp(0): MESSAGE: [1, 42, 3] |
| 54 | |
onqtam | 1655b24 | 2018-05-10 15:29:21 +0300 | [diff] [blame] | 55 | stringification.cpp(0): ERROR: CHECK( lst_1 == lst_2 ) is NOT correct! |
Salvage | 6545bdc | 2022-01-13 00:14:21 +0100 | [diff] [blame] | 56 | values: CHECK( [1, 42, 3] == [1, 2, 666] ) |
onqtam | 2c100d6 | 2017-04-16 22:47:28 +0300 | [diff] [blame] | 57 | |
Viktor Kirilov | 17d984c | 2020-12-04 15:13:33 +0200 | [diff] [blame] | 58 | stringification.cpp(0): ERROR: CHECK( s1 == s2 ) is NOT correct! |
Salvage | 4bc7a75 | 2022-01-18 05:35:57 +0100 | [diff] [blame] | 59 | values: CHECK( MyOtherType: 42 == MyOtherType: 666 ) |
Viktor Kirilov | 81fe2e8 | 2020-12-04 18:59:26 +0200 | [diff] [blame] | 60 | logged: s1=MyOtherType: 42 s2=MyOtherType: 666 |
Viktor Kirilov | 17d984c | 2020-12-04 15:13:33 +0200 | [diff] [blame] | 61 | |
| 62 | stringification.cpp(0): ERROR: CHECK( s1 == s2 ) is NOT correct! |
Salvage | 4bc7a75 | 2022-01-18 05:35:57 +0100 | [diff] [blame] | 63 | values: CHECK( MyOtherType: 42 == MyOtherType: 666 ) |
Viktor Kirilov | 81fe2e8 | 2020-12-04 18:59:26 +0200 | [diff] [blame] | 64 | logged: s1=MyOtherType: 42 s2=MyOtherType: 666 |
| 65 | MyOtherType: 42 is not really MyOtherType: 666 |
Viktor Kirilov | 17d984c | 2020-12-04 15:13:33 +0200 | [diff] [blame] | 66 | |
Salvage | 4ddb793 | 2022-01-12 16:17:39 +0100 | [diff] [blame] | 67 | stringification.cpp(0): ERROR: CHECK( doctest::IsNaN<double>(0.5) ) is NOT correct! |
Salvage | 4bc7a75 | 2022-01-18 05:35:57 +0100 | [diff] [blame] | 68 | values: CHECK( IsNaN( 0.5 ) ) |
Salvage | 245d4b2 | 2022-01-12 16:04:16 +0100 | [diff] [blame] | 69 | |
Salvage | 4ddb793 | 2022-01-12 16:17:39 +0100 | [diff] [blame] | 70 | stringification.cpp(0): ERROR: CHECK( doctest::IsNaN<float>(std::numeric_limits<float>::infinity()) ) is NOT correct! |
Salvage | 4bc7a75 | 2022-01-18 05:35:57 +0100 | [diff] [blame] | 71 | values: CHECK( IsNaN( inff ) ) |
Salvage | 245d4b2 | 2022-01-12 16:04:16 +0100 | [diff] [blame] | 72 | |
onqtam | 1655b24 | 2018-05-10 15:29:21 +0300 | [diff] [blame] | 73 | stringification.cpp(0): ERROR: test case THREW exception: MyTypeInherited<int>(5, 4) |
onqtam | 2c100d6 | 2017-04-16 22:47:28 +0300 | [diff] [blame] | 74 | |
onqtam | 35c14cd | 2017-04-24 12:54:03 +0300 | [diff] [blame] | 75 | =============================================================================== |
onqtam | 1655b24 | 2018-05-10 15:29:21 +0300 | [diff] [blame] | 76 | stringification.cpp(0): |
onqtam | 35c14cd | 2017-04-24 12:54:03 +0300 | [diff] [blame] | 77 | TEST CASE: a test case that registers an exception translator for int and then throws one |
onqtam | 27079bc | 2017-04-16 23:21:13 +0300 | [diff] [blame] | 78 | |
onqtam | 1655b24 | 2018-05-10 15:29:21 +0300 | [diff] [blame] | 79 | stringification.cpp(0): ERROR: test case THREW exception: 5 |
onqtam | 27079bc | 2017-04-16 23:21:13 +0300 | [diff] [blame] | 80 | |
onqtam | 2c100d6 | 2017-04-16 22:47:28 +0300 | [diff] [blame] | 81 | =============================================================================== |
Salvage | 6545bdc | 2022-01-13 00:14:21 +0100 | [diff] [blame] | 82 | [doctest] test cases: 3 | 0 passed | 3 failed | |
Salvage | e992f76 | 2022-01-18 06:23:45 +0100 | [diff] [blame] | 83 | [doctest] assertions: 16 | 2 passed | 14 failed | |
onqtam | 754f402 | 2017-05-06 20:07:49 +0300 | [diff] [blame] | 84 | [doctest] Status: FAILURE! |
onqtam | 2c100d6 | 2017-04-16 22:47:28 +0300 | [diff] [blame] | 85 | Program code. |