// Copyright 2019 The Chromium Authors // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "net/quic/mock_quic_context.h" namespace net { MockQuicContext::MockQuicContext() : QuicContext(std::make_unique()) { mock_helper_ = static_cast(helper()); } void MockQuicContext::AdvanceTime(quic::QuicTime::Delta delta) { mock_helper_->AdvanceTime(delta); } quic::MockClock* MockQuicContext::mock_clock() { // TODO(vasilvv): add a proper accessor to MockQuicConnectionHelper and delete // the cast. return const_cast( static_cast(mock_helper_->GetClock())); } } // namespace net