Skip to content

Commit 3f94cdf

Browse files
committed
UPD | tests #3
1 parent fa39675 commit 3f94cdf

File tree

3 files changed

+9
-2
lines changed

3 files changed

+9
-2
lines changed

src/ManapiTimerPool.cpp

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -179,10 +179,17 @@ void manapi::timerpool::stop_(std::shared_ptr<data_t> data, bool evloop) MANAPIH
179179
assert(!data->timer->stop());
180180
int const res = ::uv_loop_alive(manapi::async::current()->eventloop()->loop());
181181
assert(!data->timer->start(0, 1));
182+
manapi_log_trace(manapi::debug::LOG_TRACE_LOW, "timerpool:uv_loop_alive returned %d", res);
182183
if (!res) {
183184
data->events->stop_watcher(std::move(data->timer));
184185
}
185186
}
187+
else {
188+
manapi_log_trace(manapi::debug::LOG_TRACE_LOW, "timerpool:data->timer is NULL");
189+
}
190+
}
191+
else {
192+
manapi_log_trace(manapi::debug::LOG_TRACE_LOW, "timerpool:data->importants is %d", data->importants);
186193
}
187194
}
188195

tests/test_fs.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ UTEST(fs, read_and_write_1) {
140140

141141
manapi::async::run ([&] () -> manapi::future<> {
142142
char test[100000];
143-
auto const path = manapi::filesystem::path::join(std::filesystem::temp_directory_path(), "data-test-read_and_write_1.txt");
143+
auto const path = manapi::filesystem::path::join(".", "data-test-read_and_write_1.txt");
144144
for (int i = 0; i < 100000; i++) {
145145
test[i] = (char)(i % 10);
146146
}

tests/tools.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ inline manapi::async::shared_ctx init_ctx (int *utest_result, std::size_t timout
3131
*utest_result = UTEST_TEST_FAILURE;
3232
if (flg) {
3333
if (manapi::async::context_exists()) {
34-
::uv_print_active_handles(manapi::async::current()->eventloop()->loop(), stdout);
34+
manapi_log_debug("Active handles:");
3535
::uv_print_all_handles(manapi::async::current()->eventloop()->loop(), stdout);
3636
}
3737
exit(-1);

0 commit comments

Comments
 (0)