classwithoutinsertstreamoperator
September 14, 2025 ยท View on GitHub
Shows how to use xtd::tunit::assert class with a class to test that does not contain insert stream operator.
Sources
Build and run
Open "Command Prompt" or "Terminal". Navigate to the folder that contains the project and type the following:
xtdc run
Output
Start 2 tests from 1 test case
Run tests:
SUCCEED unit_tests::test.test_case_succeed (0 ms total)
FAILED unit_tests::test.test_case_failed (0 ms total)
Expected: 4-byte object <2A-00 00-00>
But was: 4-byte object <18-00 00-00>
Stack Trace: in |---OMITTED---|/class_without_insert_stream_operator.cpp:30
Test results:
SUCCEED 1 test.
FAILED 1 test.
End 2 tests from 1 test case ran. (0 ms total)