Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2)

Side by Side Diff: chrome/installer/util/work_item_mocks.h

Issue 1869383003: Simplify WorkItemListTest. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: no inline destructors Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_INSTALLER_UTIL_WORK_ITEM_MOCKS_H_
6 #define CHROME_INSTALLER_UTIL_WORK_ITEM_MOCKS_H_
7
8 #include "base/macros.h"
9 #include "chrome/installer/util/conditional_work_item_list.h"
10 #include "chrome/installer/util/work_item.h"
11 #include "testing/gmock/include/gmock/gmock.h"
12
13 class MockWorkItem : public WorkItem {
14 public:
15 MockWorkItem();
16 ~MockWorkItem();
17
18 MOCK_METHOD0(Do, bool());
19 MOCK_METHOD0(Rollback, void());
20
21 private:
22 DISALLOW_COPY_AND_ASSIGN(MockWorkItem);
23 };
24
25 class MockCondition : public WorkItem::Condition {
26 public:
27 MockCondition();
28 ~MockCondition();
29
30 MOCK_CONST_METHOD0(ShouldRun, bool());
31
32 private:
33 DISALLOW_COPY_AND_ASSIGN(MockCondition);
34 };
35
36 using StrictMockWorkItem = testing::StrictMock<MockWorkItem>;
37 using StrictMockCondition = testing::StrictMock<MockCondition>;
38
39 #endif // CHROME_INSTALLER_UTIL_WORK_ITEM_MOCKS_H_
OLDNEW
« no previous file with comments | « chrome/installer/util/work_item_list_unittest.cc ('k') | chrome/installer/util/work_item_mocks.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698