Source code

Revision control

Copy as Markdown

Other Tools

Test Info:

<!doctype html>
<title>Historical Geometry APIs</title>
<script src=/resources/testharness.js></script>
<script src=/resources/testharnessreport.js></script>
<script>
// Removed members
[
['DOMMatrix', 'scaleNonUniformSelf'],
['DOMMatrix', 'multiplyBy'],
['DOMMatrix', 'preMultiplyBy'],
['DOMMatrix', 'translateBy'],
['DOMMatrix', 'scaleBy'],
['DOMMatrix', 'scale3dBy'],
['DOMMatrix', 'scaleNonUniformBy'],
['DOMMatrix', 'rotateBy'],
['DOMMatrix', 'rotateFromVectorBy'],
['DOMMatrix', 'rotateAxisAngleBy'],
['DOMMatrix', 'skewXBy'],
['DOMMatrix', 'skewYBy'],
['DOMQuad', 'bounds'],
].forEach(([interf, member]) => {
test(() => {
assert_true(interf in self, `${interf} should exist`);
assert_false(member in self[interf].prototype, 'on prototype');
const instance = new self[interf]();
assert_false(member in instance, 'on instance');
}, `${interf} ${member} must be nuked`);
});
// Removed static methods
['DOMMatrix', 'DOMMatrixReadOnly'].forEach(interf => {
test(() => {
assert_true(interf in self, `${interf} should exist`);
assert_false('fromString' in self[interf], 'on interface object');
}, `${interf} fromString static member must be nuked`);
});
// Optional arguments
[
['DOMMatrixReadOnly', 'scale'],
['DOMMatrix', 'scaleSelf'],
['DOMMatrixReadOnly', 'translate'],
['DOMMatrixReadOnly', 'scale3d'],
['DOMMatrixReadOnly', 'rotateFromVector'],
['DOMMatrixReadOnly', 'rotateAxisAngle'],
['DOMMatrixReadOnly', 'skewX'],
['DOMMatrixReadOnly', 'skewY'],
['DOMMatrix', 'translateSelf'],
['DOMMatrix', 'scale3dSelf'],
['DOMMatrix', 'rotateFromVectorSelf'],
['DOMMatrix', 'rotateAxisAngleSelf'],
['DOMMatrix', 'skewXSelf'],
['DOMMatrix', 'skewYSelf'],
['DOMPointReadOnly', 'matrixTransform'],
['DOMMatrixReadOnly', 'multiply'],
['DOMMatrix', 'multiplySelf'],
['DOMMatrix', 'preMultiplySelf'],
].forEach(([interf, member]) => {
test(() => {
assert_equals(self[interf].prototype[member].length, 0, 'on prototype');
const instance = new self[interf]();
assert_equals(instance[member].length, 0, 'on instance');
}, `${interf} ${member} number of required arguments`);
});
// Renamed interfaces
[
'CSSMatrix',
'DOMMatrixImmutable',
'ClientRect',
'ClientRectList',
// Non-standard
'WebKitPoint',
'MSCSSMatrix',
].forEach(interf => {
test(() => {
assert_false(interf in self);
}, `${interf} must be nuked`);
});
</script>