Increase timeout in C++ tests from 1 to 5 seconds. (#10756)
To avoid CI failures on FreeBSD.
This commit is contained in:
@@ -181,7 +181,7 @@ void TestColumnSplitPartitioner(size_t n_samples, size_t base_rowid, std::shared
|
||||
}
|
||||
} // anonymous namespace
|
||||
|
||||
TEST(Approx, PartitionerColSplit) {
|
||||
TEST(Approx, PartitionerColumnSplit) {
|
||||
size_t n_samples = 1024, n_features = 16, base_rowid = 0;
|
||||
auto const Xy = RandomDataGenerator{n_samples, n_features, 0}.GenerateDMatrix(true);
|
||||
auto hess = GenerateHess(n_samples);
|
||||
@@ -211,7 +211,7 @@ TEST(Approx, PartitionerColSplit) {
|
||||
}
|
||||
|
||||
namespace {
|
||||
class TestApproxColSplit : public ::testing::TestWithParam<std::tuple<bool, float>> {
|
||||
class TestApproxColumnSplit : public ::testing::TestWithParam<std::tuple<bool, float>> {
|
||||
public:
|
||||
void Run() {
|
||||
auto [categorical, sparsity] = GetParam();
|
||||
@@ -220,9 +220,9 @@ class TestApproxColSplit : public ::testing::TestWithParam<std::tuple<bool, floa
|
||||
};
|
||||
} // namespace
|
||||
|
||||
TEST_P(TestApproxColSplit, Basic) { this->Run(); }
|
||||
TEST_P(TestApproxColumnSplit, Basic) { this->Run(); }
|
||||
|
||||
INSTANTIATE_TEST_SUITE_P(ColumnSplit, TestApproxColSplit, ::testing::ValuesIn([]() {
|
||||
INSTANTIATE_TEST_SUITE_P(ColumnSplit, TestApproxColumnSplit, ::testing::ValuesIn([]() {
|
||||
std::vector<std::tuple<bool, float>> params;
|
||||
for (auto categorical : {true, false}) {
|
||||
for (auto sparsity : {0.0f, 0.6f}) {
|
||||
|
||||
@@ -203,12 +203,12 @@ void TestColumnSplitPartitioner(bst_target_t n_targets) {
|
||||
}
|
||||
} // anonymous namespace
|
||||
|
||||
TEST(QuantileHist, PartitionerColSplit) { TestColumnSplitPartitioner<CPUExpandEntry>(1); }
|
||||
TEST(QuantileHist, PartitionerColumnSplit) { TestColumnSplitPartitioner<CPUExpandEntry>(1); }
|
||||
|
||||
TEST(QuantileHist, MultiPartitionerColSplit) { TestColumnSplitPartitioner<MultiExpandEntry>(3); }
|
||||
TEST(QuantileHist, MultiPartitionerColumnSplit) { TestColumnSplitPartitioner<MultiExpandEntry>(3); }
|
||||
|
||||
namespace {
|
||||
class TestHistColSplit : public ::testing::TestWithParam<std::tuple<bst_target_t, bool, float>> {
|
||||
class TestHistColumnSplit : public ::testing::TestWithParam<std::tuple<bst_target_t, bool, float>> {
|
||||
public:
|
||||
void Run() {
|
||||
auto [n_targets, categorical, sparsity] = GetParam();
|
||||
@@ -217,9 +217,9 @@ class TestHistColSplit : public ::testing::TestWithParam<std::tuple<bst_target_t
|
||||
};
|
||||
} // anonymous namespace
|
||||
|
||||
TEST_P(TestHistColSplit, Basic) { this->Run(); }
|
||||
TEST_P(TestHistColumnSplit, Basic) { this->Run(); }
|
||||
|
||||
INSTANTIATE_TEST_SUITE_P(ColumnSplit, TestHistColSplit, ::testing::ValuesIn([]() {
|
||||
INSTANTIATE_TEST_SUITE_P(ColumnSplit, TestHistColumnSplit, ::testing::ValuesIn([]() {
|
||||
std::vector<std::tuple<bst_target_t, bool, float>> params;
|
||||
for (auto categorical : {true, false}) {
|
||||
for (auto sparsity : {0.0f, 0.6f}) {
|
||||
|
||||
Reference in New Issue
Block a user