Fix clang-tidy warnings. (#4149)
* Upgrade gtest for clang-tidy. * Use CMake to install GTest instead of mv. * Don't enforce clang-tidy to return 0 due to errors in thrust. * Add a small test for tidy itself. * Reformat.
This commit is contained in:
@@ -13,7 +13,7 @@ TEST(SparsePage, PushCSC) {
|
||||
|
||||
offset = {0, 1, 4};
|
||||
for (size_t i = 0; i < offset.back(); ++i) {
|
||||
data.push_back(Entry(i, 0.1f));
|
||||
data.emplace_back(Entry(i, 0.1f));
|
||||
}
|
||||
|
||||
SparsePage other;
|
||||
@@ -52,4 +52,4 @@ TEST(SparsePage, PushCSC) {
|
||||
ASSERT_EQ(inst[i].index, indices_sol[i % 3]);
|
||||
}
|
||||
}
|
||||
}
|
||||
} // namespace xgboost
|
||||
|
||||
Reference in New Issue
Block a user