Bug 1295404 - Remove requiredFeatures from SVGTests r=dholbert r=bzbarsky

This commit is contained in:
longsonr 2019-06-26 19:51:12 +01:00
parent 94ff91d5c8
commit 020fd563bd
8 changed files with 12 additions and 23 deletions

View File

@ -11,7 +11,7 @@ function boom()
animate.setAttribute("dur", "2s");
document.documentElement.appendChild(animate);
animate.targetElement;
animate.requiredFeatures.insertItemBefore(0, 0);
animate.requiredExtensions.insertItemBefore(0, 0);
document.documentElement.setCurrentTime(4);
document.documentElement.setCurrentTime(0);
document.documentElement.removeAttribute("class");

Before

Width:  |  Height:  |  Size: 608 B

After

Width:  |  Height:  |  Size: 610 B

View File

@ -16,8 +16,7 @@
namespace mozilla {
namespace dom {
nsStaticAtom* const SVGTests::sStringListNames[3] = {
nsGkAtoms::requiredFeatures,
nsStaticAtom* const SVGTests::sStringListNames[2] = {
nsGkAtoms::requiredExtensions,
nsGkAtoms::systemLanguage,
};
@ -26,11 +25,6 @@ SVGTests::SVGTests() {
mStringListAttributes[LANGUAGE].SetIsCommaSeparated(true);
}
already_AddRefed<DOMSVGStringList> SVGTests::RequiredFeatures() {
return DOMSVGStringList::GetDOMWrapper(&mStringListAttributes[FEATURES],
AsSVGElement(), true, FEATURES);
}
already_AddRefed<DOMSVGStringList> SVGTests::RequiredExtensions() {
return DOMSVGStringList::GetDOMWrapper(&mStringListAttributes[EXTENSIONS],
AsSVGElement(), true, EXTENSIONS);

View File

@ -93,7 +93,6 @@ class SVGTests : public nsISupports {
void MaybeInvalidate();
// WebIDL
already_AddRefed<DOMSVGStringList> RequiredFeatures();
already_AddRefed<DOMSVGStringList> RequiredExtensions();
already_AddRefed<DOMSVGStringList> SystemLanguage();
@ -109,9 +108,9 @@ class SVGTests : public nsISupports {
virtual ~SVGTests() = default;
private:
enum { FEATURES, EXTENSIONS, LANGUAGE };
SVGStringList mStringListAttributes[3];
static nsStaticAtom* const sStringListNames[3];
enum { EXTENSIONS, LANGUAGE };
SVGStringList mStringListAttributes[2];
static nsStaticAtom* const sStringListNames[2];
};
NS_DEFINE_STATIC_IID_ACCESSOR(SVGTests, MOZILLA_DOMSVGTESTS_IID)

View File

@ -11,7 +11,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=724993-->
<p id="display"></p>
<div id="content" style="display:none;">
<svg id="svg" xmlns="http://www.w3.org/2000/svg" width="100" height="100">
<g id="g" requiredFeatures="foo bar baz"/>
<g id="g" requiredExtensions="foo bar baz"/>
</svg>
</div>
<pre id="test">
@ -64,7 +64,7 @@ function appendItemThrowsFor(stringList, value) {
function run_tests() {
var g = document.getElementById("g");
var strings = g.requiredFeatures;
var strings = g.requiredExtensions;
// sanity check:
is(strings.numberOfItems, 3, "numberOfItems should be 3");

View File

@ -225,9 +225,9 @@ var tests = [
{
// SVGStringList test:
target_element_id: "g",
attr_name: "requiredFeatures", // requiredExtensions, systemLanguage, viewTarget
attr_name: "requiredExtensions", // systemLanguage, viewTarget
prop_name: null, // SVGStringList attributes are not animatable
bv_name: "requiredFeatures",
bv_name: "requiredExtensions",
av_name: null,
el_type: "SVGGElement",
prop_type: null,

View File

@ -14,7 +14,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=631437
<path id="path" d="M0,0 L100,100"/>
<polygon id="poly" points="50,50 70,70 90,50"/>
<g id="g" transform="translate(20 30) rotate(50 60 70) scale(2)"
requiredFeatures="foo bar baz"/>
requiredExtensions="foo bar baz"/>
</svg>
<script type="text/javascript"><![CDATA[
@ -64,8 +64,8 @@ var tests = [
{ values: "translate(1 2) rotate(3) scale(4) skewY(5) skewX(6)",
length: 5 } ] },
{ element: g,
attribute: "requiredFeatures",
listProperty: "requiredFeatures",
attribute: "requiredExtensions",
listProperty: "requiredExtensions",
type: "SVGStringList",
subtests: [ { values: null, length: 3 },
{ values: "foo", length: 1 },

View File

@ -13,7 +13,6 @@
[NoInterfaceObject]
interface SVGTests {
readonly attribute SVGStringList requiredFeatures;
readonly attribute SVGStringList requiredExtensions;
readonly attribute SVGStringList systemLanguage;
};

View File

@ -8,9 +8,6 @@
[SVGGraphicsElement.prototype.getTransformToElement must be removed]
expected: FAIL
[SVGGraphicsElement.prototype.requiredFeatures must be removed]
expected: FAIL
[SVGSVGElement.prototype.useCurrentView must be removed]
expected: FAIL