blob: 81eaf2b27820cd2330ef09eb94074e727868ad37 [file] [log] [blame]
// Copyright 2018 The Chromium OS Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef SHILL_MOCK_EXTERNAL_TASK_H_
#define SHILL_MOCK_EXTERNAL_TASK_H_
#include <map>
#include <string>
#include <vector>
#include <gmock/gmock.h>
#include "shill/external_task.h"
namespace shill {
class MockExternalTask : public ExternalTask {
public:
MockExternalTask(ControlInterface* control,
ProcessManager* process_manager,
const base::WeakPtr<RpcTaskDelegate>& task_delegate,
const base::Callback<void(pid_t, int)>& death_callback);
~MockExternalTask() override;
MOCK_METHOD(bool,
Start,
(const base::FilePath&,
const std::vector<std::string>&,
(const std::map<std::string, std::string>&),
bool,
Error*),
(override));
MOCK_METHOD(void, Stop, (), (override));
MOCK_METHOD(void, OnDelete, ());
private:
DISALLOW_COPY_AND_ASSIGN(MockExternalTask);
};
} // namespace shill
#endif // SHILL_MOCK_EXTERNAL_TASK_H_