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

Side by Side Diff: ios/web/public/test/test_native_content.mm

Issue 2614443004: [ios] Moved all web mocks to ios/web/public/test/fakes. (Closed)
Patch Set: Moved test_redirect_observer back Created 3 years, 11 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 #import "ios/web/public/test/test_native_content.h"
6
7 #import "base/mac/scoped_nsobject.h"
8
9 @implementation TestNativeContent {
10 GURL _URL;
11 GURL _virtualURL;
12 base::scoped_nsobject<UIView> _view;
13 }
14 - (instancetype)initWithURL:(const GURL&)URL
15 virtualURL:(const GURL&)virtualURL {
16 self = [super init];
17 if (self) {
18 _URL = URL;
19 _virtualURL = virtualURL;
20 }
21 return self;
22 }
23
24 - (BOOL)respondsToSelector:(SEL)selector {
25 if (selector == @selector(virtualURL)) {
26 return _virtualURL.is_valid();
27 }
28 return [super respondsToSelector:selector];
29 }
30
31 - (NSString*)title {
32 return @"Test Title";
33 }
34
35 - (const GURL&)url {
36 return _URL;
37 }
38
39 - (GURL)virtualURL {
40 return _virtualURL;
41 }
42
43 - (UIView*)view {
44 return nil;
45 }
46
47 - (void)handleLowMemory {
48 }
49
50 - (BOOL)isViewAlive {
51 return YES;
52 }
53
54 - (void)reload {
55 }
56 @end
OLDNEW
« no previous file with comments | « ios/web/public/test/test_native_content.h ('k') | ios/web/public/test/test_native_content_provider.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698