mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 04:17: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
|
@ -2,7 +2,12 @@ loadPage("file:///res/html/misc/blank.html");
|
|||
|
||||
afterInitialPageLoad(() => {
|
||||
test("Basic functionality", () => {
|
||||
var title = document.getElementsByTagName("title")[0];
|
||||
const title = document.getElementsByTagName("title")[0];
|
||||
expect(title).toBeDefined();
|
||||
|
||||
// FIXME: Add this in once Text's constructor is implemented.
|
||||
//expect(title.firstChild).toBeInstanceOf(Text);
|
||||
|
||||
expect(title.firstChild.nodeName).toBe("#text");
|
||||
expect(title.firstChild.data).toBe("Blank");
|
||||
expect(title.firstChild.length).toBe(5);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue