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

Method TestReset

cpp/src/parquet/statistics_test.cc:429–445  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

427 }
428
429 void TestReset() {
430 this->GenerateData(1000);
431
432 auto statistics = MakeStatistics<TestType>(this->schema_.Column(0));
433 statistics->Update(this->values_ptr_, this->values_.size(), 0);
434 ASSERT_EQ(this->values_.size(), statistics->num_values());
435
436 statistics->Reset();
437 ASSERT_TRUE(statistics->HasNullCount());
438 ASSERT_FALSE(statistics->HasMinMax());
439 ASSERT_FALSE(statistics->HasDistinctCount());
440 ASSERT_EQ(0, statistics->null_count());
441 ASSERT_EQ(0, statistics->num_values());
442 ASSERT_EQ(0, statistics->distinct_count());
443 ASSERT_EQ("", statistics->EncodeMin());
444 ASSERT_EQ("", statistics->EncodeMax());
445 }
446
447 void TestMerge() {
448 int num_null[2];

Callers 1

TYPED_TESTFunction · 0.80

Calls 13

HasNullCountMethod · 0.80
HasMinMaxMethod · 0.80
HasDistinctCountMethod · 0.80
EncodeMinMethod · 0.80
EncodeMaxMethod · 0.80
GenerateDataMethod · 0.45
ColumnMethod · 0.45
UpdateMethod · 0.45
sizeMethod · 0.45
num_valuesMethod · 0.45
ResetMethod · 0.45
null_countMethod · 0.45

Tested by

no test coverage detected