From d6a10bbf51e9ddf582fb04eba74de3e264d10d30 Mon Sep 17 00:00:00 2001 From: Rodrigo Arias Mallo Date: Fri, 16 Aug 2024 22:39:37 +0200 Subject: [PATCH] Add more image aspect ratio tests --- test/html/Makefile.am | 4 +- .../render/img-aspect-ratio-mix-border.html | 42 +++++++++++++++++++ .../img-aspect-ratio-mix-border.ref.html | 42 +++++++++++++++++++ .../render/img-aspect-ratio-mix-margin.html | 42 +++++++++++++++++++ .../img-aspect-ratio-mix-margin.ref.html | 42 +++++++++++++++++++ ...-bounds.html => img-aspect-ratio-mix.html} | 0 ...ref.html => img-aspect-ratio-mix.ref.html} | 0 7 files changed, 171 insertions(+), 1 deletion(-) create mode 100644 test/html/render/img-aspect-ratio-mix-border.html create mode 100644 test/html/render/img-aspect-ratio-mix-border.ref.html create mode 100644 test/html/render/img-aspect-ratio-mix-margin.html create mode 100644 test/html/render/img-aspect-ratio-mix-margin.ref.html rename test/html/render/{img-max-bounds.html => img-aspect-ratio-mix.html} (100%) rename test/html/render/{img-max-bounds.ref.html => img-aspect-ratio-mix.ref.html} (100%) diff --git a/test/html/Makefile.am b/test/html/Makefile.am index b08649371..29daeb474 100644 --- a/test/html/Makefile.am +++ b/test/html/Makefile.am @@ -18,9 +18,11 @@ TESTS = \ render/hackernews.html \ render/img-aspect-ratio-absolute.html \ render/img-aspect-ratio-div.html \ + render/img-aspect-ratio-mix-border.html \ + render/img-aspect-ratio-mix-margin.html \ + render/img-aspect-ratio-mix.html \ render/img-aspect-ratio-relative-inside-fixed.html \ render/img-aspect-ratio.html \ - render/img-max-bounds.html \ render/main-style.html \ render/margin-auto.html \ render/max-width-body.html \ diff --git a/test/html/render/img-aspect-ratio-mix-border.html b/test/html/render/img-aspect-ratio-mix-border.html new file mode 100644 index 000000000..38cd25e82 --- /dev/null +++ b/test/html/render/img-aspect-ratio-mix-border.html @@ -0,0 +1,42 @@ + + + + Test image aspect ratio while constrained + + + +
+

All images should be 32px by 32px like this one:

+ +

Only one max-* contraint

+ + + + +

One max-* and fixed size contraint

+ + + + +

Two max-* contraints

+ + + + +

Both min-* and max-* constrained

+ + + + +

Bad constraints

+ + + + +
+ + diff --git a/test/html/render/img-aspect-ratio-mix-border.ref.html b/test/html/render/img-aspect-ratio-mix-border.ref.html new file mode 100644 index 000000000..775c8cb27 --- /dev/null +++ b/test/html/render/img-aspect-ratio-mix-border.ref.html @@ -0,0 +1,42 @@ + + + + Test image aspect ratio while constrained + + + +
+

All images should be 32px by 32px like this one:

+ +

Only one max-* contraint

+ + + + +

One max-* and fixed size contraint

+ + + + +

Two max-* contraints

+ + + + +

Both min-* and max-* constrained

+ + + + +

Bad constraints

+ + + + +
+ + diff --git a/test/html/render/img-aspect-ratio-mix-margin.html b/test/html/render/img-aspect-ratio-mix-margin.html new file mode 100644 index 000000000..af06cd76c --- /dev/null +++ b/test/html/render/img-aspect-ratio-mix-margin.html @@ -0,0 +1,42 @@ + + + + Test image aspect ratio while constrained + + + +
+

All images should be 32px by 32px like this one:

+ +

Only one max-* contraint

+ + + + +

One max-* and fixed size contraint

+ + + + +

Two max-* contraints

+ + + + +

Both min-* and max-* constrained

+ + + + +

Bad constraints

+ + + + +
+ + diff --git a/test/html/render/img-aspect-ratio-mix-margin.ref.html b/test/html/render/img-aspect-ratio-mix-margin.ref.html new file mode 100644 index 000000000..36207ab6b --- /dev/null +++ b/test/html/render/img-aspect-ratio-mix-margin.ref.html @@ -0,0 +1,42 @@ + + + + Test image aspect ratio while constrained + + + +
+

All images should be 32px by 32px like this one:

+ +

Only one max-* contraint

+ + + + +

One max-* and fixed size contraint

+ + + + +

Two max-* contraints

+ + + + +

Both min-* and max-* constrained

+ + + + +

Bad constraints

+ + + + +
+ + diff --git a/test/html/render/img-max-bounds.html b/test/html/render/img-aspect-ratio-mix.html similarity index 100% rename from test/html/render/img-max-bounds.html rename to test/html/render/img-aspect-ratio-mix.html diff --git a/test/html/render/img-max-bounds.ref.html b/test/html/render/img-aspect-ratio-mix.ref.html similarity index 100% rename from test/html/render/img-max-bounds.ref.html rename to test/html/render/img-aspect-ratio-mix.ref.html