| Index: remoting/protocol/fake_process_stats_stub.h
|
| diff --git a/remoting/protocol/fake_process_stats_stub.h b/remoting/protocol/fake_process_stats_stub.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..291e68c64f14fdacbf21674322d3cfdb4da3611c
|
| --- /dev/null
|
| +++ b/remoting/protocol/fake_process_stats_stub.h
|
| @@ -0,0 +1,34 @@
|
| +// Copyright 2017 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#include <vector>
|
| +
|
| +#include "base/callback.h"
|
| +#include "remoting/proto/process_stats.pb.h"
|
| +#include "remoting/protocol/process_stats_stub.h"
|
| +
|
| +namespace remoting {
|
| +namespace protocol {
|
| +
|
| +class FakeProcessStatsStub final : public ProcessStatsStub {
|
| + public:
|
| + FakeProcessStatsStub();
|
| + ~FakeProcessStatsStub() override;
|
| +
|
| + // ProcessStatsStub implementation.
|
| + void OnProcessStats(const AggregatedProcessResourceUsage& usage) override;
|
| +
|
| + const std::vector<AggregatedProcessResourceUsage>& received() const;
|
| +
|
| + void set_quit_closure(base::Closure quit_closure);
|
| + void set_expected_usage_count(size_t expected_usage_count);
|
| +
|
| + private:
|
| + std::vector<AggregatedProcessResourceUsage> received_;
|
| + size_t expected_usage_count_ = 0;
|
| + base::Closure quit_closure_;
|
| +};
|
| +
|
| +} // namespace protocol
|
| +} // namespace remoting
|
|
|