1
0
mirror of https://github.com/falk-werner/webfuse-provider synced 2026-03-02 04:09:18 +00:00

chore: replaced msleep by std::this_thread::sleep_for

This commit is contained in:
Falk Werner
2020-03-01 17:23:59 +01:00
parent 1a29b44ad6
commit 107e66b65a
8 changed files with 22 additions and 47 deletions

View File

@@ -1,10 +1,13 @@
#include <gtest/gtest.h>
#include "wf/jsonrpc/proxy.h"
#include "wf/timer/manager.h"
#include "webfuse/utils/msleep.hpp"
#include "webfuse/core/json_util.h"
using webfuse_test::msleep;
#include <thread>
#include <chrono>
using namespace std::chrono_literals;
#define WF_DEFAULT_TIMEOUT (10 * 1000)
@@ -289,7 +292,7 @@ TEST(wf_jsonrpc_proxy, timeout)
ASSERT_TRUE(send_context.is_called);
ASSERT_TRUE(json_is_object(send_context.response));
msleep(10);
std::this_thread::sleep_for(10ms);
wf_timer_manager_check(timer_manager);
ASSERT_TRUE(finished_context.is_called);