forked from extern/egroupware
Some work on a visual test, not yet working
This commit is contained in:
parent
33dcbc218f
commit
d25a0b215e
@ -101,5 +101,35 @@ export function inputBasicTests(before : Function, test_value : string, value_se
|
|||||||
// widget returns what we gave it
|
// widget returns what we gave it
|
||||||
assert.equal(element.get_value(), test_value);
|
assert.equal(element.get_value(), test_value);
|
||||||
});
|
});
|
||||||
})
|
});
|
||||||
|
|
||||||
|
describe("Required", () =>
|
||||||
|
{
|
||||||
|
beforeEach(async() =>
|
||||||
|
{
|
||||||
|
element = await before();
|
||||||
|
});
|
||||||
|
|
||||||
|
// This is just visually comparing for a difference, no deep inspection
|
||||||
|
it("looks different when required")
|
||||||
|
|
||||||
|
/*
|
||||||
|
Not yet working attempt to have playwright compare visually
|
||||||
|
I haven't figured out how to get it to actually work
|
||||||
|
|
||||||
|
const pre = await page.locator(element.localName).screenshot();
|
||||||
|
|
||||||
|
element.required = true;
|
||||||
|
|
||||||
|
// wait for asychronous changes to the DOM
|
||||||
|
await elementUpdated(<Element><unknown>element);
|
||||||
|
|
||||||
|
|
||||||
|
const post = await page.locator(element.localName).screenshot();
|
||||||
|
|
||||||
|
expect(post).toMatchSnapshot(pre);
|
||||||
|
|
||||||
|
*/
|
||||||
|
|
||||||
|
});
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user