MCPcopy Create free account
hub / github.com/ClickHouse/ai-sdk-cpp / assertSuccess

Method assertSuccess

tests/utils/test_fixtures.cpp:324–331  ·  view source on GitHub ↗

TestAssertions implementation

Source from the content-addressed store, hash-verified

322
323// TestAssertions implementation
324void TestAssertions::assertSuccess(const GenerateResult& result) {
325 EXPECT_TRUE(result.is_success())
326 << "Expected successful result but got error: " << result.error_message();
327 EXPECT_FALSE(result.text.empty())
328 << "Expected non-empty text in successful result";
329 EXPECT_FALSE(result.error.has_value())
330 << "Expected no error in successful result";
331}
332
333void TestAssertions::assertError(const GenerateResult& result,
334 const std::string& expected_error) {

Callers

nothing calls this directly

Calls 2

is_successMethod · 0.45
error_messageMethod · 0.45

Tested by

no test coverage detected