]> git.seodisparate.com - EntityComponentMetaSystem/commitdiff
Add tests for ThreadPool::getThreadCount()
authorStephen Seo <seo.disparate@gmail.com>
Tue, 7 Sep 2021 11:21:20 +0000 (20:21 +0900)
committerStephen Seo <seo.disparate@gmail.com>
Tue, 7 Sep 2021 11:21:20 +0000 (20:21 +0900)
src/test/ThreadPoolTest.cpp

index 31c85293bcdb1910aff8619eaffbd5d670d6a241..d5ca0d3d368de2e3890c3a5dffc9e623ad937c16 100644 (file)
@@ -66,3 +66,14 @@ TEST(ECThreadPool, Simple) {
 
     ASSERT_EQ(data.load(), 11);
 }
+
+TEST(ECThreadPool, QueryCount) {
+    {
+        OneThreadPool oneP;
+        ASSERT_EQ(1, oneP.getThreadCount());
+    }
+    {
+        ThreeThreadPool threeP;
+        ASSERT_EQ(3, threeP.getThreadCount());
+    }
+}