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

Unified Diff: third_party/WebKit/LayoutTests/plugins/keyboard-events.html

Issue 1480303002: Implement a basic PPAPI plugin for Blink layout tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix Mac by removing (hopefully) superfluous DYLD_FRAMEWORK_PATH Created 5 years 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
Index: third_party/WebKit/LayoutTests/plugins/keyboard-events.html
diff --git a/third_party/WebKit/LayoutTests/plugins/keyboard-events.html b/third_party/WebKit/LayoutTests/plugins/keyboard-events.html
index 51b773d6c9b138541ac8b58a8755737a733b9728..92d2214ee219e45425b30a7a7633056257b00638 100644
--- a/third_party/WebKit/LayoutTests/plugins/keyboard-events.html
+++ b/third_party/WebKit/LayoutTests/plugins/keyboard-events.html
@@ -1,17 +1,16 @@
<html>
<body>
-<embed name="plg" type="application/x-webkit-test-netscape" windowedPlugin="false" width=100 height=100></embed>
+<embed type="application/x-blink-test-plugin" width=100 height=100></embed>
<p>This test checks if a plugin can receive keyboard events sent from eventSender. This is a test for <a href="https://bugs.webkit.org/show_bug.cgi?id=34936">Bug 34936</a>.</p>
<script>
-
- plg.windowedPlugin = false;
- plg.eventLoggingEnabled = true;
-
+(function () {
if (!window.testRunner) {
document.write("This test does not work in manual mode.");
- } else {
- testRunner.dumpAsText();
-
+ return;
+ }
+ testRunner.dumpAsText();
+ testRunner.waitUntilDone();
+ document.querySelector('embed').addEventListener('message', function () {
// Send a mouse-click event to set the input focus to the test plugin.
eventSender.mouseMoveTo(0,0);
eventSender.mouseMoveTo(20,20);
@@ -22,10 +21,10 @@
eventSender.keyDown('a');
eventSender.keyDown('b');
eventSender.keyDown('c');
- }
-
- plg.eventLoggingEnabled = false; // stop logging so our output doesn't bleed into the next test
+ testRunner.notifyDone();
+ });
+})();
</script>
</body>
</html>

Powered by Google App Engine
This is Rietveld 408576698