OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 <string> | 5 #include <string> |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
9 #include "base/strings/stringprintf.h" | 9 #include "base/strings/stringprintf.h" |
10 #include "base/test/scoped_feature_list.h" | 10 #include "base/test/scoped_feature_list.h" |
(...skipping 185 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
196 // Navigate to different origin; the location bar should now be visible. | 196 // Navigate to different origin; the location bar should now be visible. |
197 NavigateAndCheckForLocationBar( | 197 NavigateAndCheckForLocationBar( |
198 app_browser_, "http://www.foo.com/blah", true); | 198 app_browser_, "http://www.foo.com/blah", true); |
199 } | 199 } |
200 | 200 |
201 class HostedAppVsTdiTest : public HostedAppTest { | 201 class HostedAppVsTdiTest : public HostedAppTest { |
202 public: | 202 public: |
203 HostedAppVsTdiTest() {} | 203 HostedAppVsTdiTest() {} |
204 ~HostedAppVsTdiTest() override {} | 204 ~HostedAppVsTdiTest() override {} |
205 | 205 |
| 206 void SetUp() override { |
| 207 scoped_feature_list_.InitAndEnableFeature(features::kTopDocumentIsolation); |
| 208 HostedAppTest::SetUp(); |
| 209 } |
| 210 |
206 void SetUpOnMainThread() override { | 211 void SetUpOnMainThread() override { |
207 scoped_feature_list_.InitAndEnableFeature(features::kTopDocumentIsolation); | |
208 HostedAppTest::SetUpOnMainThread(); | 212 HostedAppTest::SetUpOnMainThread(); |
209 host_resolver()->AddRule("*", "127.0.0.1"); | 213 host_resolver()->AddRule("*", "127.0.0.1"); |
210 ASSERT_TRUE(embedded_test_server()->Start()); | 214 ASSERT_TRUE(embedded_test_server()->Start()); |
211 } | 215 } |
212 | 216 |
213 private: | 217 private: |
214 base::test::ScopedFeatureList scoped_feature_list_; | 218 base::test::ScopedFeatureList scoped_feature_list_; |
215 | 219 |
216 DISALLOW_COPY_AND_ASSIGN(HostedAppVsTdiTest); | 220 DISALLOW_COPY_AND_ASSIGN(HostedAppVsTdiTest); |
217 }; | 221 }; |
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
343 } else { | 347 } else { |
344 // TODO(lukasza): https://crbug.com/718516: Process policy is not | 348 // TODO(lukasza): https://crbug.com/718516: Process policy is not |
345 // well-defined / settled wrt relationship between 1) hosted apps and 2) | 349 // well-defined / settled wrt relationship between 1) hosted apps and 2) |
346 // same-site web content outside of hosted app's extent. When this test was | 350 // same-site web content outside of hosted app's extent. When this test was |
347 // authored --site-per-process would put |app| in a separate renderer | 351 // authored --site-per-process would put |app| in a separate renderer |
348 // process from |diff_dir| and |same_site|, even though such process | 352 // process from |diff_dir| and |same_site|, even though such process |
349 // placement can be problematic (if |app| tries to synchronously script | 353 // placement can be problematic (if |app| tries to synchronously script |
350 // |diff_dir| and/or |same_site|). | 354 // |diff_dir| and/or |same_site|). |
351 } | 355 } |
352 } | 356 } |
OLD | NEW |