summaryrefslogtreecommitdiffstats
path: root/chrome/test/data
diff options
context:
space:
mode:
authorsamuong <samuong@chromium.org>2015-08-07 22:27:27 -0700
committerCommit bot <commit-bot@chromium.org>2015-08-08 05:28:18 +0000
commitaaa83e77910e8138768a1e9a702b22cada8ce791 (patch)
tree75b8f91db59e3e4ebe9fd696e4995819ea64dba2 /chrome/test/data
parente690f1765733865fae0b2ed7691e193ce66e74cb (diff)
downloadchromium_src-aaa83e77910e8138768a1e9a702b22cada8ce791.zip
chromium_src-aaa83e77910e8138768a1e9a702b22cada8ce791.tar.gz
chromium_src-aaa83e77910e8138768a1e9a702b22cada8ce791.tar.bz2
[chromedriver] Modify touch action tests to perform actions on a fixed-sized target.
Previously, these tests were performing touch actions on a div that also logged the events that were firing. Since this div would change size with every new event, touch actions would be sent to different places each time. BUG= TBR=stgao@chromium.org Review URL: https://codereview.chromium.org/1278203004 Cr-Commit-Position: refs/heads/master@{#342518}
Diffstat (limited to 'chrome/test/data')
-rw-r--r--chrome/test/data/chromedriver/touch_action_tests.html6
1 files changed, 5 insertions, 1 deletions
diff --git a/chrome/test/data/chromedriver/touch_action_tests.html b/chrome/test/data/chromedriver/touch_action_tests.html
index 46c8c8c..7f036dbb 100644
--- a/chrome/test/data/chromedriver/touch_action_tests.html
+++ b/chrome/test/data/chromedriver/touch_action_tests.html
@@ -6,6 +6,9 @@
<title>Touch Action Test Page</title>
</head>
<body>
+ <div id="target">
+ Events are logged when tests touch this div.
+ </div>
<div id="events">events: </div>
<div id="padding">
We need some padding here so that the page is large enough to test swipe
@@ -19,8 +22,9 @@
events.innerHTML += ' ' + evt.type;
};
+ var target = document.getElementById('target');
for (var i = 0; i < eventTypes.length; i++) {
- events.addEventListener(eventTypes[i], eventListener);
+ target.addEventListener(eventTypes[i], eventListener);
}
var padding = document.getElementById('padding');