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

Method Check

cpp/src/arrow/compute/kernels/aggregate_test.cc:1009–1015  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1007 Datum Expected(int64_t value) { return MakeScalar(static_cast<int64_t>(value)); }
1008
1009 void Check(Datum input, int64_t expected_all, bool has_nulls = true) {
1010 int64_t expected_valid = has_nulls ? expected_all - 1 : expected_all;
1011 int64_t expected_null = has_nulls ? 1 : 0;
1012 CheckScalar("count_distinct", {input}, Expected(expected_valid), &only_valid);
1013 CheckScalar("count_distinct", {input}, Expected(expected_null), &only_null);
1014 CheckScalar("count_distinct", {input}, Expected(expected_all), &all);
1015 }
1016
1017 void Check(const std::shared_ptr<DataType>& type, std::string_view json,
1018 int64_t expected_all, bool has_nulls = true) {

Callers

nothing calls this directly

Calls 7

CheckScalarFunction · 0.85
CheckFunction · 0.85
ArrayFromJSONFunction · 0.85
ScalarFromJSONFunction · 0.85
ResultWithFunction · 0.85
CallFunctionFunction · 0.85
MakeNullScalarFunction · 0.85

Tested by

no test coverage detected