Fix use of deprecated Boost Asio API (#535)
expires_from_now is deprecated and it is now recommended to use expires_after
diff --git a/lib/MockServer.h b/lib/MockServer.h
index 8e4a213..bd413d3 100644
--- a/lib/MockServer.h
+++ b/lib/MockServer.h
@@ -112,7 +112,7 @@
std::function<void()>&& task) {
auto timer = connection->executor_->createDeadlineTimer();
pendingTimers_[key] = timer;
- timer->expires_from_now(std::chrono::milliseconds(delayMs));
+ timer->expires_after(std::chrono::milliseconds(delayMs));
LOG_INFO("Mock scheduling " << key << " with delay " << delayMs << " ms");
auto self = shared_from_this();
timer->async_wait([this, self, key, connection, task{std::move(task)}](const auto& ec) {