| OLD | NEW |
| 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 "content/browser/site_per_process_browsertest.h" | 5 #include "content/browser/site_per_process_browsertest.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <algorithm> | 10 #include <algorithm> |
| (...skipping 702 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 713 public: | 713 public: |
| 714 SitePerProcessFeaturePolicyBrowserTest() {} | 714 SitePerProcessFeaturePolicyBrowserTest() {} |
| 715 | 715 |
| 716 protected: | 716 protected: |
| 717 void SetUpCommandLine(base::CommandLine* command_line) override { | 717 void SetUpCommandLine(base::CommandLine* command_line) override { |
| 718 SitePerProcessBrowserTest::SetUpCommandLine(command_line); | 718 SitePerProcessBrowserTest::SetUpCommandLine(command_line); |
| 719 // TODO(iclelland): Remove this switch when Feature Policy ships. | 719 // TODO(iclelland): Remove this switch when Feature Policy ships. |
| 720 // https://crbug.com/623682 | 720 // https://crbug.com/623682 |
| 721 command_line->AppendSwitchASCII( | 721 command_line->AppendSwitchASCII( |
| 722 switches::kEnableBlinkFeatures, | 722 switches::kEnableBlinkFeatures, |
| 723 "FeaturePolicy,FeaturePolicyExperimentalFeatures"); | 723 "FeaturePolicy,FeaturePolicyExperimentalFeatures," |
| 724 "FullscreenInFeaturePolicy"); |
| 724 } | 725 } |
| 725 | 726 |
| 726 ParsedFeaturePolicyHeader CreateFPHeader( | 727 ParsedFeaturePolicyHeader CreateFPHeader( |
| 727 blink::WebFeaturePolicyFeature feature, | 728 blink::WebFeaturePolicyFeature feature, |
| 728 const std::vector<GURL>& origins) { | 729 const std::vector<GURL>& origins) { |
| 729 ParsedFeaturePolicyHeader result(1); | 730 ParsedFeaturePolicyHeader result(1); |
| 730 result[0].feature = feature; | 731 result[0].feature = feature; |
| 731 result[0].matches_all_origins = false; | 732 result[0].matches_all_origins = false; |
| 732 DCHECK(!origins.empty()); | 733 DCHECK(!origins.empty()); |
| 733 for (const GURL& origin : origins) | 734 for (const GURL& origin : origins) |
| (...skipping 9430 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 10164 names.insert(root->children[0]->frame_entry->frame_unique_name()); | 10165 names.insert(root->children[0]->frame_entry->frame_unique_name()); |
| 10165 } | 10166 } |
| 10166 | 10167 |
| 10167 // More than one entry in the set means that the subframe frame navigation | 10168 // More than one entry in the set means that the subframe frame navigation |
| 10168 // entries didn't have a consistent unique name. This will break history | 10169 // entries didn't have a consistent unique name. This will break history |
| 10169 // navigations =( | 10170 // navigations =( |
| 10170 EXPECT_THAT(names, SizeIs(1)) << "Mismatched names for subframe!"; | 10171 EXPECT_THAT(names, SizeIs(1)) << "Mismatched names for subframe!"; |
| 10171 } | 10172 } |
| 10172 | 10173 |
| 10173 } // namespace content | 10174 } // namespace content |
| OLD | NEW |