From 8ef2c6a55a340c36686b0b0bffdbdaede3b2e558 Mon Sep 17 00:00:00 2001 From: oreqizer Date: Mon, 22 Jan 2024 11:36:11 +0100 Subject: [PATCH] docs: update visual testing --- .github/contribution/testing-conventions.md | 22 +++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/.github/contribution/testing-conventions.md b/.github/contribution/testing-conventions.md index 76ff08e0f3..8aed1bb910 100644 --- a/.github/contribution/testing-conventions.md +++ b/.github/contribution/testing-conventions.md @@ -97,6 +97,9 @@ screenshots, you need to run the tests on Linux. You can do that by running the - `yarn run docker:reset` - `yarn components test-ct --update-snapshots` +> Note: you may encounter some installation script errors. This is normal and can be ignored. The +> same applies to running the tests the first time. + After you're done, reset the environment: - `yarn run docker:reset` @@ -106,6 +109,25 @@ Both `darwin` and `linux` screenshots are kept: - `darwin` screenshots are for fast local development experience - `linux` screenshots are for CI +#### Colima + +To use [Colima](https://github.com/abiosoft/colima) as your Docker engine, set it up as so: + +```shell +brew install colima +brew install docker docker-compose +mkdir -p ~/.docker/cli-plugins +ln -sfn $(brew --prefix)/opt/docker-compose/bin/docker-compose ~/.docker/cli-plugins/docker-compose +brew install docker-buildx +ln -sfn $(brew --prefix)/opt/docker-buildx/bin/docker-buildx ~/.docker/cli-plugins/docker-buildx +colima start --cpu 4 --memory 4 --disk 100 +``` + +#### Reviewing the changes + +If you're satisfied with the changes, commit them and push them to the repository. In GitHub, the +reviewer can conveniently see difference in before/after images when checking side-by-side. + ### Track down the regression with `git bisect` If you aren't sure where the visual regression came from, which is often the case for this workflow