MCPcopy Create free account
hub / github.com/apache/arrow / CheckUnifyFailsTypeError

Method CheckUnifyFailsTypeError

cpp/src/arrow/type_test.cc:985–998  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

983 }
984
985 void CheckUnifyFailsTypeError(
986 const std::shared_ptr<Field>& field1, const std::shared_ptr<Field>& field2,
987 const Field::MergeOptions& options = Field::MergeOptions::Defaults(),
988 const std::string& match_message = "") {
989 ARROW_SCOPED_TRACE("options: ", options);
990 ARROW_SCOPED_TRACE("field2: ", field2->ToString());
991 ARROW_SCOPED_TRACE("field1: ", field1->ToString());
992 ASSERT_RAISES(TypeError, field1->MergeWith(field2, options));
993 ASSERT_RAISES(TypeError, field2->MergeWith(field1, options));
994 EXPECT_RAISES_WITH_MESSAGE_THAT(TypeError, ::testing::HasSubstr(match_message),
995 field1->MergeWith(field2, options));
996 EXPECT_RAISES_WITH_MESSAGE_THAT(TypeError, ::testing::HasSubstr(match_message),
997 field2->MergeWith(field1, options));
998 }
999
1000 void CheckPromoteTo(
1001 const std::shared_ptr<DataType>& left, const std::shared_ptr<DataType>& right,

Callers

nothing calls this directly

Calls 4

MergeWithMethod · 0.80
DefaultsFunction · 0.70
fieldFunction · 0.70
ToStringMethod · 0.45

Tested by

no test coverage detected