| 110 | #ifndef _WIN32 |
| 111 | |
| 112 | TEST_F(TestAtFork, EmptyHandlers) { |
| 113 | # ifndef ARROW_ENABLE_THREADING |
| 114 | GTEST_SKIP() << "Test requires threading support"; |
| 115 | # endif |
| 116 | |
| 117 | auto handlers = std::make_shared<AtForkHandler>(); |
| 118 | |
| 119 | RegisterAtFork(handlers); |
| 120 | RegisterAtFork(handlers); |
| 121 | |
| 122 | RunInChild([&]() { |
| 123 | ASSERT_TRUE(before_.empty()); |
| 124 | ASSERT_TRUE(parent_after_.empty()); |
| 125 | ASSERT_TRUE(child_after_.empty()); |
| 126 | }); |
| 127 | |
| 128 | ASSERT_TRUE(before_.empty()); |
| 129 | ASSERT_TRUE(parent_after_.empty()); |
| 130 | ASSERT_TRUE(child_after_.empty()); |
| 131 | |
| 132 | handlers.reset(); |
| 133 | |
| 134 | RunInChild([]() {}); |
| 135 | } |
| 136 | |
| 137 | TEST_F(TestAtFork, SingleThread) { |
| 138 | # ifndef ARROW_ENABLE_THREADING |
nothing calls this directly
no test coverage detected