mi6 / ic-ui-kit

Intelligence Community UI Kit (based on StencilJS)
MIT License
24 stars 25 forks source link

Migration of testing to Cypress #1166

Open MI6-255 opened 11 months ago

MI6-255 commented 11 months ago

Summary

Migration of testing to Cypress in a duplicate repository.

💬 Description

This issue completes the work for the initial technical setup for the move to Cypress for all forms of testing, this includes:

This should include tests for both Web Components and React. However, some thought should be given to the scalability of having to duplicate some tests in React, if that is even useful. For example, for Slotted SVG, it would be useful as otherwise it would not be covered. Consideration here for the effort required to duplicate the tests initially, but also the time it would take to run all the different types of tests in the pipeline.

This issue should not only include the setup of all kinds of tests, but also the following:

As a final output of this issue, the following two issues need to be created:

💰 Use value

To initially test if Cypress works for our use case (StencilJS/web components), and if there are any blockers to our adoption, before we move this work into production.

Long term, this will allow us to simplify our testing stack to do all our tests with one technology (Cypress) as opposed to using various (Jest, Puppeteer, Loki, Axe etc), but add the additional benefits of performance testing and fixing issues with our current visual testing.

Overall, this will improve our product quality.

Additional info

This issue sets the ground work for the follow up issue of moving it across to the ui-kit, so it'd be best to set it up in a way where it can be copied across. After that, there will be more issues to work through all components to move tests across.

MI6-255 commented 11 months ago

This issue will benefit from being split up.