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

Side by Side Diff: content/child/site_isolation_policy_unittest.cc

Issue 24012002: Move Range code to gfx. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: d Created 7 years, 3 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 | Annotate | Revision Log
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 #include "base/strings/utf_string_conversions.h" 5 #include "base/strings/utf_string_conversions.h"
6 #include "content/child/site_isolation_policy.h" 6 #include "content/child/site_isolation_policy.h"
7 #include "content/public/common/context_menu_params.h" 7 #include "content/public/common/context_menu_params.h"
8 #include "testing/gtest/include/gtest/gtest.h" 8 #include "testing/gtest/include/gtest/gtest.h"
9 #include "third_party/WebKit/public/platform/WebURLResponse.h" 9 #include "third_party/WebKit/public/platform/WebURLResponse.h"
10 #include "ui/base/range/range.h" 10 #include "ui/gfx/range/range.h"
11 11
12 namespace content { 12 namespace content {
13 13
14 TEST(SiteIsolationPolicyTest, IsBlockableScheme) { 14 TEST(SiteIsolationPolicyTest, IsBlockableScheme) {
15 GURL data_url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAA=="); 15 GURL data_url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAA==");
16 GURL ftp_url("ftp://google.com"); 16 GURL ftp_url("ftp://google.com");
17 GURL mailto_url("mailto:google@google.com"); 17 GURL mailto_url("mailto:google@google.com");
18 GURL about_url("about:chrome"); 18 GURL about_url("about:chrome");
19 GURL http_url("http://google.com"); 19 GURL http_url("http://google.com");
20 GURL https_url("https://google.com"); 20 GURL https_url("https://google.com");
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 128
129 EXPECT_TRUE(SiteIsolationPolicy::SniffForJS(js_data, arraysize(js_data))); 129 EXPECT_TRUE(SiteIsolationPolicy::SniffForJS(js_data, arraysize(js_data)));
130 EXPECT_FALSE( 130 EXPECT_FALSE(
131 SiteIsolationPolicy::SniffForJS(json_data, arraysize(json_data))); 131 SiteIsolationPolicy::SniffForJS(json_data, arraysize(json_data)));
132 132
133 // Basic bounds check. 133 // Basic bounds check.
134 EXPECT_FALSE(SiteIsolationPolicy::SniffForJS(basic_js_data, 0)); 134 EXPECT_FALSE(SiteIsolationPolicy::SniffForJS(basic_js_data, 0));
135 } 135 }
136 136
137 } // namespace content 137 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/web_contents/touch_editable_impl_aura.cc ('k') | content/common/content_param_traits.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698