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

Unified Diff: ios/clean/chrome/browser/ui/tools/tools_mediator_unittest.mm

Issue 2812463002: [ios clean] Creates ToolsMenu UnitTests (Closed)
Patch Set: CL Feedback Created 3 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 side-by-side diff with in-line comments
Download patch
Index: ios/clean/chrome/browser/ui/tools/tools_mediator_unittest.mm
diff --git a/ios/clean/chrome/browser/ui/tools/tools_mediator_unittest.mm b/ios/clean/chrome/browser/ui/tools/tools_mediator_unittest.mm
new file mode 100644
index 0000000000000000000000000000000000000000..5329a2f8be50af07f8a1226d1f2c73059255fd11
--- /dev/null
+++ b/ios/clean/chrome/browser/ui/tools/tools_mediator_unittest.mm
@@ -0,0 +1,30 @@
+// 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.
+
+#import "ios/clean/chrome/browser/ui/tools/tools_mediator.h"
+
+#import "ios/clean/chrome/browser/ui/tools/tools_consumer.h"
+#include "testing/platform_test.h"
+#import "third_party/ocmock/OCMock/OCMock.h"
+#include "third_party/ocmock/gtest_support.h"
+
+#if !defined(__has_feature) || !__has_feature(objc_arc)
+#error "This file requires ARC support."
+#endif
+
+namespace {
+
+class ToolsMediatorTest : public PlatformTest {
+ protected:
+ ToolsMediator* mediator_;
+};
+
+TEST_F(ToolsMediatorTest, TestSetConsumer) {
+ id consumer = OCMProtocolMock(@protocol(ToolsConsumer));
+ mediator_ = [[ToolsMediator alloc] initWithConsumer:consumer];
+
+ [[consumer verify] setToolsMenuItems:[OCMArg any]];
+}
+
+} // namespace

Powered by Google App Engine
This is Rietveld 408576698