Chromium Code Reviews| Index: chrome/test/data/extensions/api_test/browser_action/open_popup/open_popup_fails.js |
| diff --git a/chrome/test/data/extensions/api_test/browser_action/open_popup/open_popup_fails.js b/chrome/test/data/extensions/api_test/browser_action/open_popup/open_popup_fails.js |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..230e3a137c7baca76471003014e9daea994e098c |
| --- /dev/null |
| +++ b/chrome/test/data/extensions/api_test/browser_action/open_popup/open_popup_fails.js |
| @@ -0,0 +1,16 @@ |
| +// Copyright (c) 2013 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +// Notify pass to return control to the ApiTest. This needs to be done in 2 |
| +// passes so we can open the popup from the ApiTest side because loading an |
| +// extension hides any open popups. After a popup is opened, we can assert that |
|
Finnur
2013/10/17 14:58:34
Do you know why that is?
justinlin
2013/10/17 18:32:53
Oh, well I haven't dug into this, but it seems lik
|
| +// a popup fails to open with this API. |
| +chrome.test.notifyPass(); |
| +chrome.test.sendMessage('ready', function() { |
| + chrome.browserAction.openPopup(function(popupWindow2) { |
| + // This popup should fail to open. |
| + chrome.test.assertTrue(!popupWindow2); |
| + chrome.test.succeed(); |
| + }); |
| +}); |