| 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 "base/strings/string_number_conversions.h" | 5 #include "base/strings/string_number_conversions.h" |
| 6 #include "build/build_config.h" | 6 #include "build/build_config.h" |
| 7 #include "chrome/browser/extensions/extension_apitest.h" | 7 #include "chrome/browser/extensions/extension_apitest.h" |
| 8 #include "net/dns/mock_host_resolver.h" | 8 #include "net/dns/mock_host_resolver.h" |
| 9 | 9 |
| 10 class ExecuteScriptApiTest : public ExtensionApiTest { | 10 class ExecuteScriptApiTest : public ExtensionApiTest { |
| (...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 128 IN_PROC_BROWSER_TEST_P(DestructiveScriptTest, SynchronousRemoval) { | 128 IN_PROC_BROWSER_TEST_P(DestructiveScriptTest, SynchronousRemoval) { |
| 129 ASSERT_TRUE(RunSubtest("synchronous")) << message_; | 129 ASSERT_TRUE(RunSubtest("synchronous")) << message_; |
| 130 } | 130 } |
| 131 | 131 |
| 132 // Removes the frame at the frame's first scheduled microtask. | 132 // Removes the frame at the frame's first scheduled microtask. |
| 133 IN_PROC_BROWSER_TEST_P(DestructiveScriptTest, MicrotaskRemoval) { | 133 IN_PROC_BROWSER_TEST_P(DestructiveScriptTest, MicrotaskRemoval) { |
| 134 ASSERT_TRUE(RunSubtest("microtask")) << message_; | 134 ASSERT_TRUE(RunSubtest("microtask")) << message_; |
| 135 } | 135 } |
| 136 | 136 |
| 137 // Removes the frame at the frame's first scheduled macrotask. | 137 // Removes the frame at the frame's first scheduled macrotask. |
| 138 IN_PROC_BROWSER_TEST_P(DestructiveScriptTest, MacrotaskRemoval) { | 138 // Test is flaky. crbug.com/722703 |
| 139 IN_PROC_BROWSER_TEST_P(DestructiveScriptTest, DISABLED_MacrotaskRemoval) { |
| 139 ASSERT_TRUE(RunSubtest("macrotask")) << message_; | 140 ASSERT_TRUE(RunSubtest("macrotask")) << message_; |
| 140 } | 141 } |
| 141 | 142 |
| 142 // Removes the frame at the first DOMNodeInserted event. | 143 // Removes the frame at the first DOMNodeInserted event. |
| 143 IN_PROC_BROWSER_TEST_P(DestructiveScriptTest, DOMNodeInserted1) { | 144 IN_PROC_BROWSER_TEST_P(DestructiveScriptTest, DOMNodeInserted1) { |
| 144 ASSERT_TRUE(RunSubtest("domnodeinserted1")) << message_; | 145 ASSERT_TRUE(RunSubtest("domnodeinserted1")) << message_; |
| 145 } | 146 } |
| 146 | 147 |
| 147 // Removes the frame at the second DOMNodeInserted event. | 148 // Removes the frame at the second DOMNodeInserted event. |
| 148 IN_PROC_BROWSER_TEST_P(DestructiveScriptTest, DOMNodeInserted2) { | 149 IN_PROC_BROWSER_TEST_P(DestructiveScriptTest, DOMNodeInserted2) { |
| (...skipping 16 matching lines...) Expand all Loading... |
| 165 } | 166 } |
| 166 | 167 |
| 167 // Removes the frame at the third DOMSubtreeModified event. | 168 // Removes the frame at the third DOMSubtreeModified event. |
| 168 IN_PROC_BROWSER_TEST_P(DestructiveScriptTest, DOMSubtreeModified3) { | 169 IN_PROC_BROWSER_TEST_P(DestructiveScriptTest, DOMSubtreeModified3) { |
| 169 ASSERT_TRUE(RunSubtest("domsubtreemodified3")) << message_; | 170 ASSERT_TRUE(RunSubtest("domsubtreemodified3")) << message_; |
| 170 } | 171 } |
| 171 | 172 |
| 172 INSTANTIATE_TEST_CASE_P(ExecuteScriptApiTest, | 173 INSTANTIATE_TEST_CASE_P(ExecuteScriptApiTest, |
| 173 DestructiveScriptTest, | 174 DestructiveScriptTest, |
| 174 ::testing::Range(0, kDestructiveScriptTestBucketCount)); | 175 ::testing::Range(0, kDestructiveScriptTestBucketCount)); |
| OLD | NEW |