You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I set the viewport to 1000x600px and then take a screenshot, the resulting screenshot is 800x600px wide. This only happens when running inside Docker.
Start the test server with npm start, which will fire up a server at http://localhost:9000.
Ensure Docker for Mac is running and then run npm run test-d (which runs docker run -it -v $PWD:/cypress -w /cypress --entrypoint=cypress cypress/included:3.8.2 run --config baseUrl=http://host.docker.internal:9000 --headless --browser chrome).
Check the resolution of screenshots/main.spec.js/Cypress Viewport Test -- works.png.
Versions
Cypress 3.8.2 (running in Docker using cypress/included:3.8.2)
Docker for Mac 2.2.0.0
macOS 10.12.6
Node 13.6.0 (running in nvm and used for the project, not in Docker)
The text was updated successfully, but these errors were encountered:
steveharrison
changed the title
1000px becomes 800px-wide in Docker + Chrome + Headless
Screenshots taken in 1000px viewport are 800px wide in Docker + Chrome + Headless
Jan 27, 2020
Current behavior:
When I set the viewport to 1000x600px and then take a screenshot, the resulting screenshot is 800x600px wide. This only happens when running inside Docker.
Desired behavior:
I expect the screenshot to be 1000px wide.
I've read @brian-mann's post about issues with taking screenshots larger than 1280x720px, but 1000x600px is within these dimensions.
Test code to reproduce
npm i
.npm start
, which will fire up a server athttp://localhost:9000
.npm run test-d
(which runsdocker run -it -v $PWD:/cypress -w /cypress --entrypoint=cypress cypress/included:3.8.2 run --config baseUrl=http://host.docker.internal:9000 --headless --browser chrome
).screenshots/main.spec.js/Cypress Viewport Test -- works.png
.Versions
nvm
and used for the project, not in Docker)The text was updated successfully, but these errors were encountered: