-
Notifications
You must be signed in to change notification settings - Fork 133
Open
Description
Slightly adjusted example from the README.md:
using namespace boost; // nothrow is ambiguous
using namespace boost::ut;
constexpr auto sum(auto... values) { return (values + ...); }
int main() {
using namespace boost::ut;
"sum"_test = [] {
expect(2 == 0_i) << "message";
expect(sum(2, 2) == 3_i);
expect(sum(1, 2) > 0_i and 41_i == sum(40, 2));
};
}produces:
Running test "sum"... FAILED
in: /tests/main.cpp:13 - test condition: [2 == 0]
message
Running test "sum"... FAILED
in: /tests/main.cpp:13 - test condition: [2 == 0] messageFAILED
in: /tests/main.cpp:14 - test condition: [4 == 3]
Running test "sum"... FAILED
in: /tests/main.cpp:13 - test condition: [2 == 0] messageFAILED
in: /tests/main.cpp:14 - test condition: [4 == 3]FAILED
in: /tests/main.cpp:15 - test condition: [(3 > 0 and 41 == 42)]
===============================================================================
Suite global
tests: 1 | 3 failed
asserts: 3 | 0 passed | 3 failed
Terminal process exited with code 255.
Why is everything like this?! 🤯
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels