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

Unified Diff: chrome_frame/test/test_mock_with_web_server.h

Issue 2375003: Add chrome_frame_tests to check that some navigation cases are not broken in ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome_frame/test/simulate_input.cc ('k') | chrome_frame/test/test_mock_with_web_server.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome_frame/test/test_mock_with_web_server.h
===================================================================
--- chrome_frame/test/test_mock_with_web_server.h (revision 48538)
+++ chrome_frame/test/test_mock_with_web_server.h (working copy)
@@ -75,15 +75,22 @@
MOCK_METHOD2(OnWindowDetected, void (HWND hwnd, // NOLINT
const std::string& caption));
- // Test expectations
+ // Test expectations for general navigations.
ExpectationSet ExpectNavigationCardinality(const std::wstring& url,
testing::Cardinality cardinality);
ExpectationSet ExpectNavigation(const std::wstring& url);
ExpectationSet ExpectNavigationAndSwitch(const std::wstring& url);
ExpectationSet ExpectNavigationAndSwitchSequence(const std::wstring& url);
ExpectationSet ExpectNewWindow(MockWebBrowserEventSink* new_window_mock);
- ExpectationSet MockWebBrowserEventSink::ExpectNavigationSequenceForAnchors(
- const std::wstring& url);
+ ExpectationSet ExpectNavigationSequenceForAnchors(const std::wstring& url);
+
+ // Test expectations for navigations with an IE renderer.
+ // Expect one navigation to occur.
+ ExpectationSet ExpectNavigationInIE(const std::wstring& url);
+ // Expect a new window to be opened to |url|. Set |new_window_mock| as the new
+ // window.
+ ExpectationSet ExpectNewWindowWithIE(
+ const std::wstring& url, MockWebBrowserEventSink* new_window_mock);
};
ACTION_P(CloseBrowserMock, mock) {
@@ -94,6 +101,11 @@
mock->ExpectAddressBarUrl(std::wstring(arg0));
}
+ACTION_P4(DelaySendScanCode, loop, delay, c, mod) {
+ loop->PostDelayedTask(FROM_HERE, NewRunnableFunction(
+ simulate_input::SendScanCode, c, mod), delay);
+}
+
} // namespace chrome_frame_test
#endif // CHROME_FRAME_TEST_MOCK_WITH_WEB_SERVER_H_
« no previous file with comments | « chrome_frame/test/simulate_input.cc ('k') | chrome_frame/test/test_mock_with_web_server.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698