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

Side by Side Diff: chrome/browser/extensions/stubs_apitest.cc

Issue 366024: Add stub functions for chrome.* APIs in content scripts. ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/chrome.gyp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Property Changes:
Added: svn:eol-style
+ LF
OLDNEW
(Empty)
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "chrome/browser/extensions/extension_apitest.h"
6 #include "chrome/common/chrome_paths.h"
7 #include "chrome/test/ui_test_utils.h"
8
9 #if defined(OS_WIN) // TODO(asargent) get this working on linux
10 // Tests that we throw errors when you try using extension APIs that aren't
11 // supported in content scripts.
12 //
13 // If you have added a new API to extension_api.json and this test starts
14 // failing, most likely you need to either mark it as "unprivileged" (if it
15 // should be available in content scripts) or update the list of privileged APIs
16 // in renderer_extension_bindings.js.
17 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, Stubs) {
18 ASSERT_TRUE(RunExtensionTest("stubs")) << message_;
19
20 // Navigate to a simple file:// page, which should get the content script
21 // injected and run the rest of the test.
22 FilePath test_dir;
23 ASSERT_TRUE(PathService::Get(chrome::DIR_TEST_DATA, &test_dir));
24 FilePath simple_html_path = test_dir.AppendASCII("simple.html");
25 ui_test_utils::NavigateToURL(browser(),
26 GURL(simple_html_path.value()));
27 ResultCatcher catcher;
28 ASSERT_TRUE(catcher.GetNextResult());
29 }
30 #endif
OLDNEW
« no previous file with comments | « no previous file | chrome/chrome.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698