No subject
Mon Jan 28 08:41:14 PST 2013
> LayoutTests/editing/text-iterator/script-tests/basic-iteration.js:35
> +var input = testDocument.body.children[0];
I would prefer doing testDocument.querySelector('input') instead.
> LayoutTests/editing/text-iterator/script-tests/basic-iteration.js:37
> +var shadow = internals.oldestShadowRoot(input);
> +shouldBe('range.selectNodeContents(shadow); internals.rangeAsText(range)', '"b"');
It would have been better if we called internals.oldestShadowRoot(input) inside shouldBe.
> LayoutTests/editing/text-iterator/script-tests/basic-iteration.js:41
> +var mydiv = shadow.childNodes[0];
> +var mybr = document.createElement('br');
> +mydiv.appendChild(mybr);
Please don't use variables names like mydiv and mybr.
Also, it would have been better if we added a helper function to create and append a br element and then called that inside shouldBe.
> LayoutTests/editing/text-iterator/script-tests/basic-iteration.js:46
> +testDocument.body.innerHTML = '<div>a</div>';
> +var maindiv = testDocument.body.childNodes[0];
> +var shadow = maindiv.webkitCreateShadowRoot();
We should create some helper function to do this and call it inside shouldBe.
> LayoutTests/editing/text-iterator/script-tests/basic-iteration.js:49
> +shadow.appendChild(document.createElement('br'));
This should be called inside shouldBe.
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list