blob: cb0e4dfc3446f8f6c1dd0ad4ce41eafe57136949 [file] [log] [blame]
[email protected]d24bd382012-02-11 16:17:521<!DOCTYPE html>
2<html>
3<head>
4<meta charset="utf-8">
[email protected]efb086342013-11-05 00:56:215<script src="../../resources/js-test.js"></script>
[email protected]d24bd382012-02-11 16:17:526</head>
7<body>
8<script>
9
10description("Tests that Node.isEqualNode behaves correctly after an element that originally had attributes has had them removed.");
11
12e1 = document.createElement('span');
13e2 = document.createElement('span');
14
15shouldBe("e1.isEqualNode(e2)", "true");
16e2.setAttribute("foo", "bar");
17shouldBe("e1.isEqualNode(e2)", "false");
18e2.removeAttribute("foo");
19shouldBe("e1.isEqualNode(e2)", "true");
20
21e1 = document.createElement('span');
22e2 = document.createElement('span');
23
24shouldBe("e1.isEqualNode(e2)", "true");
25e1.setAttribute("foo", "bar");
26shouldBe("e1.isEqualNode(e2)", "false");
27e1.removeAttribute("foo");
28shouldBe("e1.isEqualNode(e2)", "true");
29
30</script>
[email protected]d24bd382012-02-11 16:17:5231</body>
32</html>