1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 14:27:35 +00:00

LibWeb: Add a test for getComputedStyle()

Print out the value of each property in the computed-style of the body
element. This is by no means a thorough test that we're serializing
every property's value correctly in every configuration, (and in fact,
some are definitely wrong,) but it does give us a nice baseline.
This commit is contained in:
Sam Atkins 2023-09-29 17:25:15 +01:00 committed by Andreas Kling
parent a3a5af3fd1
commit b8ede72107
2 changed files with 174 additions and 0 deletions

View file

@ -0,0 +1,9 @@
<script src="../include.js"></script>
<script>
test(() => {
const style = getComputedStyle(document.body);
for (const property_name of style) {
println(`${property_name}: ${style[property_name]}`);
}
});
</script>