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

Side by Side Diff: ios/chrome/browser/chrome_url_util_unittest.mm

Issue 1544743002: Switch to standard integer types in ios/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #import "ios/chrome/browser/chrome_url_util.h" 5 #import "ios/chrome/browser/chrome_url_util.h"
6 6
7 #include "base/macros.h"
7 #include "ios/chrome/browser/chrome_url_constants.h" 8 #include "ios/chrome/browser/chrome_url_constants.h"
8 #import "net/base/mac/url_conversions.h" 9 #import "net/base/mac/url_conversions.h"
9 #import "testing/gtest_mac.h" 10 #import "testing/gtest_mac.h"
10 #include "url/gurl.h" 11 #include "url/gurl.h"
11 12
12 namespace { 13 namespace {
13 14
14 TEST(ChromeURLUtilTest, TestIsExternalFileReference) { 15 TEST(ChromeURLUtilTest, TestIsExternalFileReference) {
15 GURL external_url("chrome://external-file/foo/bar"); 16 GURL external_url("chrome://external-file/foo/bar");
16 GURL not_external_url("chrome://foo/bar"); 17 GURL not_external_url("chrome://foo/bar");
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 for (unsigned int i = 0; i < arraysize(kSchemeTestData); ++i) { 56 for (unsigned int i = 0; i < arraysize(kSchemeTestData); ++i) {
56 const char* url = kSchemeTestData[i]; 57 const char* url = kSchemeTestData[i];
57 bool nsurl_result = UrlHasChromeScheme( 58 bool nsurl_result = UrlHasChromeScheme(
58 [NSURL URLWithString:[NSString stringWithUTF8String:url]]); 59 [NSURL URLWithString:[NSString stringWithUTF8String:url]]);
59 bool gurl_result = GURL(url).SchemeIs(kChromeUIScheme); 60 bool gurl_result = GURL(url).SchemeIs(kChromeUIScheme);
60 EXPECT_EQ(gurl_result, nsurl_result) << "Scheme check failed for " << url; 61 EXPECT_EQ(gurl_result, nsurl_result) << "Scheme check failed for " << url;
61 } 62 }
62 } 63 }
63 64
64 } // namespace 65 } // namespace
OLDNEW
« no previous file with comments | « ios/chrome/browser/chrome_url_constants.cc ('k') | ios/chrome/browser/crash_report/breakpad_helper.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698