| | |
| | | Works with any unit testing framework. |
| | | |
| | | ## Big Picture |
| | | > From the previous exercise; we created a simple pipeline. We will now flesh it out with some testing to add gates to our pathway to production. |
| | | |
| | | This exercise begins cluster containing blah blah |
| | | ![big-picture](../images/big-picture/big-picture-3.jpg) |
| | | |
| | | --- |
| | | |
| | |
| | | #### 1a - FE Unit tests |
| | | > In this exercise we will execute our test for the front end locally. Once verified we will add them to Jenkins. |
| | | |
| | | 2. Before linking our automated testing to the pipeline we'll first ensure the tests run locally. Change to the `todolist-fe` directory and run `test`. |
| | | 1. Before linking our automated testing to the pipeline we'll first ensure the tests run locally. Change to the `todolist-fe` directory and run `test`. |
| | | ```bash |
| | | cd todolist-fe |
| | | ``` |
| | |
| | | npm run test |
| | | ``` |
| | | |
| | | 2. Navigate to your instance of Jenkins at `https://jenkins-<YOUR_NAME>-ci-cd.apps.lader.rht-labs.com/`. |
| | | 2. Navigate to your instance of Jenkins at `https://jenkins-<YOUR_NAME>-ci-cd.<APPS_URL>`. |
| | | Click on `dev-todolist-fe-build` and then click the `configure` button on the left-hand side. |
| | | ![jenkins-configure-job](../images/exercise3/jenkins-configure-job.png) |
| | | |
| | |
| | | |
| | | 2. On the Build section; add a build step to execute shell and fill in the following substituting `<YOUR_NAME>` accordingly: |
| | | ```bash |
| | | export E2E_TEST_ROUTE=todolist-fe-<YOUR_NAME>-dev.apps.lader.rht-labs.com |
| | | export E2E_TEST_ROUTE=todolist-fe-<YOUR_NAME>-dev.<APPS_URL> |
| | | npm install |
| | | npm run e2e:ci |
| | | ``` |