<!DOCTYPE html>
<title>SVGIntegerOptionalInteger value range</title>
<script src="../../resources/testharness.js"></script>
<script src="../../resources/testharnessreport.js"></script>
<script>
test(function() {
var element = document.createElementNS('http://www.w3.org/2000/svg', 'feConvolveMatrix');
element.setAttribute('order', '2147483648');
assert_equals(element.orderX.baseVal, 2147483647);
element.setAttribute('order', '-2147483649');
assert_equals(element.orderX.baseVal, -2147483648);
}, document.title+', outside range of int.');
test(function() {
var element = document.createElementNS('http://www.w3.org/2000/svg', 'feConvolveMatrix');
element.setAttribute('order', '2147483578');
assert_equals(element.orderX.baseVal, 2147483647);
}, document.title+', not exactly representable as int.');
</script>