Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / dom / Element / class-list-move-between-document-with-different-quirks-mode.html
blobb5101a2be522e9a75121d5882f41b5c5438ce538
1 <!DOCTYPE html>
2 <script src="../../../resources/js-test.js"></script>
3 <iframe></iframe>
4 <script>
6 description('Tests that moving an element between documents with different quirks mode works');
8 var htmlElement = document.createElement('div');
9 htmlElement.className = "A a B";
11 debug('In standards mode');
12 shouldBeTrue('htmlElement.classList.contains("A")');
13 shouldBeTrue('htmlElement.classList.contains("a")');
14 shouldBeTrue('htmlElement.classList.contains("B")');
15 shouldBeFalse('htmlElement.classList.contains("b")');
17 var doc = frames[0].document;
18 doc.open();
19 doc.write('<body></body>');
20 doc.close();
22 debug('Moved to quirks mode');
23 doc.body.appendChild(htmlElement);
24 shouldBeTrue('htmlElement.classList.contains("A")');
25 shouldBeTrue('htmlElement.classList.contains("a")');
26 shouldBeTrue('htmlElement.classList.contains("B")');
27 shouldBeFalse('htmlElement.classList.contains("b")');
29 debug('Moved back to standards mode');
30 document.body.appendChild(htmlElement);
31 shouldBeTrue('htmlElement.classList.contains("A")');
32 shouldBeTrue('htmlElement.classList.contains("a")');
33 shouldBeTrue('htmlElement.classList.contains("B")');
34 shouldBeFalse('htmlElement.classList.contains("b")');
36 </script>