blob: 4f4ca135871366e2fd95de7e25e0147627361a8f [file] [log] [blame]
Verify the nth-child() pseudo class does not leak registers.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
PASS document.querySelectorAll("body:nth-child(n) div:nth-child(n) ul:nth-child(n) li:nth-child(n) span:nth-child(n) span:nth-child(n) span:nth-child(n) span:nth-child(n) span:nth-child(n) span:nth-child(n)").length is 1
PASS getComputedStyle(document.getElementById("target")).backgroundColor is "rgb(1, 2, 3)"
PASS document.querySelectorAll("body:nth-child(n+1) div:nth-child(n+1) ul:nth-child(n+1) li:nth-child(n+1) span:nth-child(n+1) span:nth-child(n+1) span:nth-child(n+1) span:nth-child(n+1) span:nth-child(n+1) span:nth-child(n+1)").length is 1
PASS getComputedStyle(document.getElementById("target")).color is "rgb(4, 5, 6)"
PASS document.querySelectorAll("body:nth-child(1) div:nth-child(1) ul:nth-child(1) li:nth-child(1) span:nth-child(1) span:nth-child(1) span:nth-child(1) span:nth-child(1) span:nth-child(1) span:nth-child(1)").length is 0
PASS document.querySelectorAll("body:nth-child(2) div:nth-child(2) ul:nth-child(2) li:nth-child(2) span:nth-child(2) span:nth-child(2) span:nth-child(2) span:nth-child(2) span:nth-child(2) span:nth-child(2)").length is 0
PASS document.querySelectorAll("body:nth-child(2n) div:nth-child(2n) ul:nth-child(2n) li:nth-child(2n) span:nth-child(2n) span:nth-child(2n) span:nth-child(2n) span:nth-child(2n) span:nth-child(2n) span:nth-child(2n)").length is 0
PASS document.querySelectorAll("body:nth-child(2n+1) div:nth-child(2n+1) ul:nth-child(2n+1) li:nth-child(2n+1) span:nth-child(2n+1) span:nth-child(2n+1) span:nth-child(2n+1) span:nth-child(2n+1) span:nth-child(2n+1) span:nth-child(2n+1)").length is 0
PASS successfullyParsed is true
TEST COMPLETE