mirror of
https://github.com/RGBCube/serenity
synced 2025-07-10 03:57:35 +00:00
LibWeb: Add more document tests, add comment, text and mixin tests
Also adds a TypeScript definition file for the test runner object.
This commit is contained in:
parent
8b807e65d7
commit
c2a2552e46
18 changed files with 224 additions and 15 deletions
16
Libraries/LibWeb/Tests/HTML/document.head.js
Normal file
16
Libraries/LibWeb/Tests/HTML/document.head.js
Normal file
|
@ -0,0 +1,16 @@
|
|||
loadPage("file:///res/html/misc/blank.html");
|
||||
|
||||
afterInitialPageLoad(() => {
|
||||
test("Basic functionality", () => {
|
||||
expect(document.head).not.toBeNull();
|
||||
// FIXME: Add this in once HTMLHeadElement's constructor is implemented.
|
||||
//expect(document.head).toBeInstanceOf(HTMLHeadElement);
|
||||
expect(document.head.nodeName).toBe("head");
|
||||
});
|
||||
|
||||
// FIXME: Add this in once removeChild is implemented.
|
||||
test.skip("Nullable", () => {
|
||||
document.documentElement.removeChild(document.head);
|
||||
expect(document.head).toBeNull();
|
||||
});
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue