| Index: third_party/WebKit/LayoutTests/imported/wpt/innerText/setter.html
|
| diff --git a/third_party/WebKit/LayoutTests/imported/wpt/innerText/setter.html b/third_party/WebKit/LayoutTests/imported/wpt/innerText/setter.html
|
| index 7fc198a79ce21a4638cb71ac8498aafbc4aa1c91..c2ffb37df13d44eecf93c102960fd5dc3aa34e14 100644
|
| --- a/third_party/WebKit/LayoutTests/imported/wpt/innerText/setter.html
|
| +++ b/third_party/WebKit/LayoutTests/imported/wpt/innerText/setter.html
|
| @@ -16,21 +16,25 @@ function setupTest(context, plain) {
|
| while (e && e.nodeType != Node.ELEMENT_NODE) {
|
| e = e.nextSibling;
|
| }
|
| + var oldChild = e.firstChild;
|
| e.innerText = plain;
|
| - return e;
|
| + return [e, oldChild];
|
| }
|
| function testText(context, plain, expectedText, msg) {
|
| test(function(){
|
| - var e = setupTest(context, plain);
|
| + var arr = setupTest(context, plain);
|
| + var e = arr[0];
|
| + var oldChild = arr[1];
|
| assert_not_equals(e.firstChild, null, "Should have a child");
|
| assert_equals(e.firstChild.nodeType, Node.TEXT_NODE, "Child should be a text node");
|
| assert_equals(e.firstChild.nextSibling, null, "Should have only one child");
|
| assert_equals(e.firstChild.data, expectedText);
|
| + assert_not_equals(e.firstChild, oldChild, "Child should be a *new* text node");
|
| }, msg);
|
| }
|
| function testHTML(context, plain, expectedHTML, msg) {
|
| test(function(){
|
| - var e = setupTest(context, plain);
|
| + var e = setupTest(context, plain)[0];
|
| assert_equals(e.innerHTML, expectedHTML);
|
| }, msg);
|
| }
|
|
|