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

Side by Side Diff: ios/web/public/test/earl_grey/js_test_util.h

Issue 2340533004: [ios] Implemented -[ShellEarlGrey loadURL:]. (Closed)
Patch Set: Do not wait for Window ID injection if content is not HTML. Created 4 years, 3 months 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
OLDNEW
(Empty)
1 // Copyright 2016 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 #ifndef IOS_WEB_PUBLIC_TEST_EARL_GREY_JS_TEST_UTIL_H_
6 #define IOS_WEB_PUBLIC_TEST_EARL_GREY_JS_TEST_UTIL_H_
7
8 #import <Foundation/Foundation.h>
9
10 #import "ios/web/public/web_state/web_state.h"
11
12 namespace web {
13
14 // Waits until the Window ID has been injected and the page is thus ready to
15 // respond to JavaScript injection. Fails on timeout or if unrecoverable error
baxley 2016/09/14 15:43:26 Should we clarify that it fails with a GREYAssert,
Eugene But (OOO till 7-30) 2016/09/14 16:25:29 Done.
16 // (such as no web view) occurs.
17 void WaitUntilWindowIdInjected(WebState* web_state);
18
19 // Executes |javascript| on the given |web_state|, and waits until execution is
20 // completed. If |out_error| is not nil, it is set to the error resulting from
21 // the execution, if one occurs. The return value is the result of the
22 // JavaScript execution. If the script execution is timed out, then this method
23 // fails.
baxley 2016/09/14 15:43:26 Similar to the last comment, do you think it's goo
Eugene But (OOO till 7-30) 2016/09/14 16:25:29 Done.
24 id ExecuteJavaScript(WebState* web_state,
25 NSString* javascript,
26 NSError** out_error);
27
28 } // namespace web
29
30 #endif // IOS_WEB_PUBLIC_TEST_EARL_GREY_JS_TEST_UTIL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698