Skip to content

Commit f96a68d

Browse files
committed
Add tags to the thread pool tests.
1 parent a747aea commit f96a68d

File tree

1 file changed

+12
-8
lines changed

1 file changed

+12
-8
lines changed

tiledb/common/thread_pool/test/unit_thread_pool.cc

+12-8
Original file line numberDiff line numberDiff line change
@@ -109,13 +109,13 @@ void wait_all(
109109
}
110110
}
111111

112-
TEST_CASE("ThreadPool: Test empty", "[threadpool]") {
112+
TEST_CASE("ThreadPool: Test empty", "[threadpool][empty]") {
113113
for (int i = 0; i < 10; i++) {
114114
ThreadPool pool{4};
115115
}
116116
}
117117

118-
TEST_CASE("ThreadPool: Test single thread", "[threadpool]") {
118+
TEST_CASE("ThreadPool: Test single thread", "[threadpool][single-thread]") {
119119
bool use_wait = GENERATE(true, false);
120120
std::atomic<int> result = 0; // needs to be atomic b/c scavenging thread can
121121
// run in addition to thread pool
@@ -133,7 +133,8 @@ TEST_CASE("ThreadPool: Test single thread", "[threadpool]") {
133133
REQUIRE(result == 100);
134134
}
135135

136-
TEST_CASE("ThreadPool: Test multiple threads", "[threadpool]") {
136+
TEST_CASE(
137+
"ThreadPool: Test multiple threads", "[threadpool][multiple-threads]") {
137138
bool use_wait = GENERATE(true, false);
138139
std::atomic<int> result(0);
139140
std::vector<ThreadPool::Task> results;
@@ -152,7 +153,7 @@ struct AtomicHolder {
152153
std::atomic<int> val_;
153154
};
154155

155-
TEST_CASE("ThreadPool: Test no wait", "[threadpool]") {
156+
TEST_CASE("ThreadPool: Test no wait", "[threadpool][no-wait]") {
156157
{
157158
ThreadPool pool{4};
158159
auto ptr = tdb::make_shared<AtomicHolder>(HERE(), 0);
@@ -224,7 +225,8 @@ TEST_CASE(
224225
// }
225226
// }
226227

227-
TEST_CASE("ThreadPool: Test recursion, simplest case", "[threadpool]") {
228+
TEST_CASE(
229+
"ThreadPool: Test recursion, simplest case", "[threadpool][recursion]") {
228230
bool use_wait = GENERATE(true, false);
229231
ThreadPool pool{1};
230232

@@ -247,7 +249,7 @@ TEST_CASE("ThreadPool: Test recursion, simplest case", "[threadpool]") {
247249
REQUIRE(result == 1);
248250
}
249251

250-
TEST_CASE("ThreadPool: Test recursion", "[threadpool]") {
252+
TEST_CASE("ThreadPool: Test recursion", "[threadpool][recursion]") {
251253
bool use_wait = GENERATE(true, false);
252254
size_t num_threads = 0;
253255
SECTION("- One thread") {
@@ -320,7 +322,9 @@ TEST_CASE("ThreadPool: Test recursion", "[threadpool]") {
320322
cv.wait(ul);
321323
}
322324

323-
TEST_CASE("ThreadPool: Test recursion, two pools", "[threadpool]") {
325+
TEST_CASE(
326+
"ThreadPool: Test recursion, two pools",
327+
"[threadpool][recursion][two-pools]") {
324328
bool use_wait = GENERATE(true, false);
325329
size_t num_threads = 0;
326330

@@ -428,7 +432,7 @@ TEST_CASE("ThreadPool: Test recursion, two pools", "[threadpool]") {
428432
}
429433
}
430434

431-
TEST_CASE("ThreadPool: Test Exceptions", "[threadpool]") {
435+
TEST_CASE("ThreadPool: Test Exceptions", "[threadpool][exceptions]") {
432436
bool use_wait = GENERATE(true, false);
433437
std::atomic<int> result(0);
434438
ThreadPool pool{7};

0 commit comments

Comments
 (0)