Skip to content

Commit d4d7ea4

Browse files
committed
test: shrink the pinned viewport to 640x400 and regenerate the images
GitHub scales README images down to its column width but never up, so the 1280x720 captures rendered at ~69% while carrying mostly whitespace. At 640x400 they render 1:1 and the form fills a meaningful share of the frame.
1 parent 2fed03f commit d4d7ea4

9 files changed

Lines changed: 5 additions & 3 deletions

File tree

-3.22 KB
Loading
-3.59 KB
Loading
-3.95 KB
Loading
-3.22 KB
Loading
-3.59 KB
Loading
-5.51 KB
Loading
-3.2 KB
Loading
-3.16 KB
Loading

reference-app/src/test/java/com/ardetrick/oryhydrareference/OryHydraReferenceApplicationFunctionalTests.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -123,10 +123,12 @@ void stopTestEnvironment() {
123123
oryHydraContainer.stop();
124124
}
125125

126-
// Every screenshot these tests capture is destined for the docs, so the viewport is pinned
127-
// rather than left at Playwright's default — a Playwright upgrade must not resize the images.
126+
// Every screenshot these tests capture is destined for the docs, so the viewport is pinned —
127+
// a Playwright upgrade must not resize the images. 640x400 rather than the 1280x720 default
128+
// because GitHub scales README images down to its ~880px column but never up: captures
129+
// narrower than the column render 1:1, and the unstyled pages carry less dead space.
128130
private Page newPage() {
129-
return browser.newPage(new Browser.NewPageOptions().setViewportSize(1280, 720));
131+
return browser.newPage(new Browser.NewPageOptions().setViewportSize(640, 400));
130132
}
131133

132134
@BeforeEach

0 commit comments

Comments
 (0)