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

Side by Side Diff: components/test_runner/test_runner.h

Issue 2278303002: Remove the allow-displaying-mixed-content setting from Blink. (Closed)
Patch Set: Cleanup before adding reviewers. Created 4 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #ifndef COMPONENTS_TEST_RUNNER_TEST_RUNNER_H_ 5 #ifndef COMPONENTS_TEST_RUNNER_TEST_RUNNER_H_
6 #define COMPONENTS_TEST_RUNNER_TEST_RUNNER_H_ 6 #define COMPONENTS_TEST_RUNNER_TEST_RUNNER_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <deque> 10 #include <deque>
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 class MockWebUserMediaClient; 47 class MockWebUserMediaClient;
48 class SpellCheckClient; 48 class SpellCheckClient;
49 class TestInterfaces; 49 class TestInterfaces;
50 class TestRunnerForSpecificView; 50 class TestRunnerForSpecificView;
51 class WebTestDelegate; 51 class WebTestDelegate;
52 52
53 // TestRunner class currently has dual purpose: 53 // TestRunner class currently has dual purpose:
54 // 1. It implements |testRunner| javascript bindings for "global" / "ambient". 54 // 1. It implements |testRunner| javascript bindings for "global" / "ambient".
55 // Examples: 55 // Examples:
56 // - testRunner.dumpAsText (test flag affecting test behavior) 56 // - testRunner.dumpAsText (test flag affecting test behavior)
57 // - testRunner.setAllowDisplayOfInsecureContent (test flag affecting product 57 // - testRunner.setAllowRunningOfInsecureContent (test flag affecting product
58 // behavior) 58 // behavior)
59 // - testRunner.setTextSubpixelPositioning (directly interacts with product). 59 // - testRunner.setTextSubpixelPositioning (directly interacts with product).
60 // Note that "per-view" (non-"global") bindings are handled by 60 // Note that "per-view" (non-"global") bindings are handled by
61 // instances of TestRunnerForSpecificView class. 61 // instances of TestRunnerForSpecificView class.
62 // 2. It manages global test state. Example: 62 // 2. It manages global test state. Example:
63 // - Tracking topLoadingFrame that can finish the test when it loads. 63 // - Tracking topLoadingFrame that can finish the test when it loads.
64 // - WorkQueue holding load requests from the TestInterfaces 64 // - WorkQueue holding load requests from the TestInterfaces
65 // - LayoutTestRuntimeFlags 65 // - LayoutTestRuntimeFlags
66 class TestRunner : public WebTestRunner { 66 class TestRunner : public WebTestRunner {
67 public: 67 public:
(...skipping 331 matching lines...) Expand 10 before | Expand all | Expand 10 after
399 // This function sets a flag that tells the test_shell to dump the MIME type 399 // This function sets a flag that tells the test_shell to dump the MIME type
400 // for each resource that was loaded. It takes no arguments, and ignores any 400 // for each resource that was loaded. It takes no arguments, and ignores any
401 // that may be present. 401 // that may be present.
402 void DumpResourceResponseMIMETypes(); 402 void DumpResourceResponseMIMETypes();
403 403
404 // WebContentSettingsClient related. 404 // WebContentSettingsClient related.
405 void SetImagesAllowed(bool allowed); 405 void SetImagesAllowed(bool allowed);
406 void SetScriptsAllowed(bool allowed); 406 void SetScriptsAllowed(bool allowed);
407 void SetStorageAllowed(bool allowed); 407 void SetStorageAllowed(bool allowed);
408 void SetPluginsAllowed(bool allowed); 408 void SetPluginsAllowed(bool allowed);
409 void SetAllowDisplayOfInsecureContent(bool allowed);
410 void SetAllowRunningOfInsecureContent(bool allowed); 409 void SetAllowRunningOfInsecureContent(bool allowed);
411 void SetAutoplayAllowed(bool allowed); 410 void SetAutoplayAllowed(bool allowed);
412 void DumpPermissionClientCallbacks(); 411 void DumpPermissionClientCallbacks();
413 412
414 // Sets up a mock DocumentSubresourceFilter to disallow subsequent subresource 413 // Sets up a mock DocumentSubresourceFilter to disallow subsequent subresource
415 // loads within the current document with the given path |suffixes|. The 414 // loads within the current document with the given path |suffixes|. The
416 // filter is created and injected even if |suffixes| is empty. If |suffixes| 415 // filter is created and injected even if |suffixes| is empty. If |suffixes|
417 // contains the empty string, all subresource loads will be disallowed. 416 // contains the empty string, all subresource loads will be disallowed.
418 void SetDisallowedSubresourcePathSuffixes( 417 void SetDisallowedSubresourcePathSuffixes(
419 const std::vector<std::string>& suffixes); 418 const std::vector<std::string>& suffixes);
(...skipping 225 matching lines...) Expand 10 before | Expand all | Expand 10 after
645 bool is_web_platform_tests_mode_; 644 bool is_web_platform_tests_mode_;
646 645
647 base::WeakPtrFactory<TestRunner> weak_factory_; 646 base::WeakPtrFactory<TestRunner> weak_factory_;
648 647
649 DISALLOW_COPY_AND_ASSIGN(TestRunner); 648 DISALLOW_COPY_AND_ASSIGN(TestRunner);
650 }; 649 };
651 650
652 } // namespace test_runner 651 } // namespace test_runner
653 652
654 #endif // COMPONENTS_TEST_RUNNER_TEST_RUNNER_H_ 653 #endif // COMPONENTS_TEST_RUNNER_TEST_RUNNER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698