From 0efaa7495117bddf5c6513890e9de19c03357b0c Mon Sep 17 00:00:00 2001 From: "ala'n (Alexey Stsefanovich)" Date: Thu, 15 Feb 2024 17:26:46 +0100 Subject: [PATCH] docs(e2e): fixes for the root `e2e` submodule README Co-authored-by: Yuliya Adamska Co-authored-by: Dmitry Shovchko --- e2e/README.md | 27 +++++++++++++-------------- 1 file changed, 13 insertions(+), 14 deletions(-) diff --git a/e2e/README.md b/e2e/README.md index b541ed15f1..3fcbd3b820 100644 --- a/e2e/README.md +++ b/e2e/README.md @@ -2,17 +2,17 @@ ## Introduction This is an internal package for visual automation testing the ESL. -It is designed to be used by the ESL team to test ESL library by checking visual consistency of `@exadel/esl-webside` submodule. +It is designed to be used by the ESL team to test the ESL library by checking the visual consistency of `@exadel/esl-website` submodule. ## Installation -There is no extra pre-conditions to develop new visual tests locally, +There are no extra pre-conditions to develop new visual tests locally, everything to start will be already installed with root package installation. -**⚠️ Except for one critical thing: all final snapshots should be created on Linux based OS (Ubuntu latest version is recommended) ⚠️** +**⚠️ Except for one critical thing: all final snapshots should be created on Linux based OS (the latest version of Ubuntu is recommended) ⚠️** -Visual testing depends on fonts rendering so snapshots created on different OS may be different. -The main (remote) environment for visual testing runs via GitHub Workflows on Ubuntu latest version. +Visual testing depends on font rendering so snapshots created on different OS may be different. +The main (remote) environment for visual testing runs via GitHub Workflows on the latest version of Ubuntu. ### Creating snapshots and running existing tests on Windows @@ -28,7 +28,7 @@ To create snapshots on Windows, you need to use WSL (Windows Subsystem for Linux nvm install node@20 nvm use node@20 ``` -4. Install cromium browser (https://learn.microsoft.com/en-us/windows/wsl/tutorials/gui-apps#install-google-chrome-for-linux): +4. Install Chromium browser (https://learn.microsoft.com/en-us/windows/wsl/tutorials/gui-apps#install-google-chrome-for-linux): ```bash sudo apt-get update sudo apt-get install -y chromium-browser @@ -38,9 +38,9 @@ To create snapshots on Windows, you need to use WSL (Windows Subsystem for Linux sudo apt install libgtk-3-dev libnotify-dev libgconf-2-4 libnss3 libxss1 libasound2 ``` Note: you might need to restart your subsystem after steps 4 and 5. -6. Open project folder via WSL terminal and run `npm install` to ensure all dependencies are installed. +6. Open the project folder via WSL terminal and run `npm install` to ensure all dependencies are installed. 7. Use `e2e` package scripts to create snapshots and run tests: - - `npm run test:e2e` (in the root package) or `npm run run` (in sub-package) to run all tests (missing snapshots will be created automatically) + - `npm run test:e2e` (in the root package) or `npm run run` (in the sub-package) to run all tests (missing snapshots will be created automatically) - `npm run test:e2e:update` (in the root package) or `npm run run:update` (in sub-package) to update all snapshots ### Creating snapshots and running existing tests on Mac @@ -49,10 +49,10 @@ TODO: add instructions for Mac OS ### Creating snapshots and running existing tests on Linux -To create snapshots on Linux, you can use any Linux distribution, but Ubuntu latest version is recommended. +To create snapshots on Linux, you can use any Linux distribution, but the latest version of Ubuntu is recommended. -1. Install ESL root package and all dependencies according to the root package README.md. -2. Ensure you have chromium browser installed: +1. Install the ESL root package and all dependencies according to the root package README.md. +2. Ensure you have Chromium browser installed: ```bash sudo apt-get update sudo apt-get install -y chromium-browser @@ -69,18 +69,17 @@ Use explicit workspace name to run following commands from the root package. - `npm run run` - run all visual tests (run server automatically, create missing snapshots) - `npm run run:update` - update all snapshots (run server automatically) -- `npm run run:server` - shortcut to run server for visual tests (uses `esl-webside` package) +- `npm run run:server` - shortcut to run server for visual tests (uses `esl-website` package) - `npm run run:update:only` - update all snapshots, does not run server (ensure you run server manually) - `npm run run:server:only` - run server for visual tests, does not run tests Note: default server port for visual tests is `3007`. - ## Updating snapshots using GitHub project workflow The Automated tests workflow allows you to trigger it manually, it will update all snapshots and commit changes on the branch you specify. -Make sure you have permissions to run workflows in the ESL repository or ask the ESL Maintainers team to run the proper update for you. +Make sure you have permission to run workflows in the ESL repository or ask the ESL Maintainers team to run the proper update for you. To trigger the workflow manually, follow these steps: