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

Side by Side Diff: ios/chrome/browser/ui/content_suggestions/content_suggestions_image_updater_unittest.mm

Issue 2691593002: Connect ContentSuggestionsMediator to the ContentService (Closed)
Patch Set: Address comments Created 3 years, 10 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 2017 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 #import "ios/chrome/browser/ui/content_suggestions/content_suggestions_image_upd ater.h"
6
7 #import <UIKit/UIKit.h>
8
9 #include "testing/gtest/include/gtest/gtest.h"
10 #import "third_party/ocmock/OCMock/OCMock.h"
11 #include "third_party/ocmock/gtest_support.h"
12
13 #if !defined(__has_feature) || !__has_feature(objc_arc)
14 #error "This file requires ARC support."
15 #endif
16
17 TEST(ContentSuggestionsImageUpdaterTest, receivedImage) {
18 // Setup.
19 UIImage* image = [[UIImage alloc] init];
20 id delegateMock =
21 OCMProtocolMock(@protocol(ContentSuggestionsImageUpdaterDelegate));
22 ContentSuggestionsImageUpdater* imageUpdater =
23 [[ContentSuggestionsImageUpdater alloc] init];
24 imageUpdater.delegate = delegateMock;
25
26 // Action.
27 [imageUpdater receivedImage:image];
28
29 // Test.
30 EXPECT_OCMOCK_VERIFY(delegateMock);
31 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698