<!DOCTYPE html>
<script src='../../../resources/testharness.js'></script>
<script src='../../../resources/testharnessreport.js'></script>
<style type="text/css">
#box {
width: 300px;
height: 100px;
}
</style>
<div id="box" ></div>
<script type="text/javascript">
test(function(t) {
if (window.chrome && chrome.gpuBenchmarking) {
var exception;
try {
chrome.gpuBenchmarking.smoothScrollByXY(0, 300, function() {}, -1, -1);
} catch(e) {
exception = e;
}
assert_not_equals(exception, undefined);
}
}, 'Test that chrome.gpuBenchmarking.smoothScrollByXY throws an exception on invalid input values.');
test(function(t) {
if (window.chrome && chrome.gpuBenchmarking) {
var exception;
try {
chrome.gpuBenchmarking.smoothDrag(-1, -1, 200, 200);
} catch(e) {
exception = e;
}
assert_not_equals(exception, undefined);
}
}, 'Test that chrome.gpuBenchmarking.smoothDrag throws an exception on invalid input values.');
test(function(t) {
if (window.chrome && chrome.gpuBenchmarking) {
var exception;
try {
chrome.gpuBenchmarking.pinchBy(2, -1, -1);
} catch(e) {
exception = e;
}
assert_not_equals(exception, undefined);
}
}, 'Test that chrome.gpuBenchmarking.pinchBy throws an exception on invalid input values.');
test(function(t) {
if (window.chrome && chrome.gpuBenchmarking) {
var exception;
try {
chrome.gpuBenchmarking.tap(-1, -1, t.unreached_func('Listener should not fire'));
} catch(e) {
exception = e;
}
assert_not_equals(exception, undefined);
}
}, 'Test that chrome.gpuBenchmarking.tap throws an exception on invalid input values.');
test(function(t) {
if (window.chrome && chrome.gpuBenchmarking) {
var exception;
try {
chrome.gpuBenchmarking.scrollBounce("down", 0, 0, t.unreached_func('Listener should not fire'), -1, -1);
} catch(e) {
exception = e;
}
assert_not_equals(exception, undefined);
}
}, 'Test that chrome.gpuBenchmarking.scrollBounce throws an exception on invalid input values.');
</script>