Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
These are the CI steps for the following two items: - nodejs lint - nodejs unit tests using Cypress component testing The Cypress e2e test is not yet included in this PR. 1. The Cypress e2e test will have to mobilize headless browser engines, which requires several graphics libraries to be installed to the system. So we have two options for preparing the environment: A: use the default ubuntu distribution and install those graphic libraries or B: use the Cypress officially prepared docker image and install other toolchains (eg. make) as needed. For the sake of increasing the likelihood of running Cypress test suite successfully, I chose the latter. 2. In order to reuse the installed Cypress executables (installed through `npm install`) I decided to cache the Cypress installation cache. Also I packaged the installed `node_modules` together with the code base. The cache (in the form of tar files) are passed over to the depending jobs. The successive jobs do not need to check the code out again. 3. Another reason for tarring the files is because it preserves file permissions, otherwise with the default `upload-artifact` GH action, all file permission will be set to 644. This is noted [here](https://github.com/actions/upload-artifact?tab=readme-ov-file#permission-loss).
- Loading branch information