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

Side by Side Diff: content/browser/child_process_security_policy_unittest.cc

Issue 637183002: Replace FINAL and OVERRIDE with their C++11 counterparts in content (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased the patch Created 6 years, 2 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
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 <set> 5 #include <set>
6 #include <string> 6 #include <string>
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/files/file_path.h" 9 #include "base/files/file_path.h"
10 #include "content/browser/child_process_security_policy_impl.h" 10 #include "content/browser/child_process_security_policy_impl.h"
(...skipping 16 matching lines...) Expand all
27 #define TEST_PATH(x) FILE_PATH_LITERAL("c:") FILE_PATH_LITERAL(x) 27 #define TEST_PATH(x) FILE_PATH_LITERAL("c:") FILE_PATH_LITERAL(x)
28 #else 28 #else
29 #define TEST_PATH(x) FILE_PATH_LITERAL(x) 29 #define TEST_PATH(x) FILE_PATH_LITERAL(x)
30 #endif 30 #endif
31 31
32 class ChildProcessSecurityPolicyTestBrowserClient 32 class ChildProcessSecurityPolicyTestBrowserClient
33 : public TestContentBrowserClient { 33 : public TestContentBrowserClient {
34 public: 34 public:
35 ChildProcessSecurityPolicyTestBrowserClient() {} 35 ChildProcessSecurityPolicyTestBrowserClient() {}
36 36
37 virtual bool IsHandledURL(const GURL& url) OVERRIDE { 37 virtual bool IsHandledURL(const GURL& url) override {
38 return schemes_.find(url.scheme()) != schemes_.end(); 38 return schemes_.find(url.scheme()) != schemes_.end();
39 } 39 }
40 40
41 void ClearSchemes() { 41 void ClearSchemes() {
42 schemes_.clear(); 42 schemes_.clear();
43 } 43 }
44 44
45 void AddScheme(const std::string& scheme) { 45 void AddScheme(const std::string& scheme) {
46 schemes_.insert(scheme); 46 schemes_.insert(scheme);
47 } 47 }
(...skipping 587 matching lines...) Expand 10 before | Expand all | Expand 10 after
635 // queried on the IO thread. The ChildProcessSecurityPolicy needs to be 635 // queried on the IO thread. The ChildProcessSecurityPolicy needs to be
636 // prepared to answer policy questions about renderers who no longer exist. 636 // prepared to answer policy questions about renderers who no longer exist.
637 637
638 // In this case, we default to secure behavior. 638 // In this case, we default to secure behavior.
639 EXPECT_FALSE(p->CanRequestURL(kRendererID, url)); 639 EXPECT_FALSE(p->CanRequestURL(kRendererID, url));
640 EXPECT_FALSE(p->CanReadFile(kRendererID, file)); 640 EXPECT_FALSE(p->CanReadFile(kRendererID, file));
641 EXPECT_FALSE(p->HasWebUIBindings(kRendererID)); 641 EXPECT_FALSE(p->HasWebUIBindings(kRendererID));
642 } 642 }
643 643
644 } // namespace content 644 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/child_process_security_policy_impl.h ('k') | content/browser/cocoa/system_hotkey_map_unittest.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698