Run unit tests Copy Note Notice that you named this new step using keywords and used keywords to run arbitrary commands. This work is now complete and ready for testing. n the repository. Now the workflow is defined on the branch. But the workflow is only triggered when you submit a pull request against that branch. Create a new branch named Copy In this new branch make minor changes by adding comments to the files Copy Now commit these changes and push them to the remote repository. storage The repository is not currently aware of branches so you need to specify that the source should use the branch named copy to handle these changes as the new branch is now available on the remote repository. Create a pull request to merge this branch into the branch.
Go to the repository in your b photo editing servies rowser. In the Pull Requests tab at the top of the page you should see a Compare and Pull Requests button because there was a recent push to the PR tab. Click that button to open a pull request. You should navigate to a new page. On that new page click the Create Pull Request button to open the Pull Request creation page Once you have opened the pull request you should see a yellow box above the Merge Pull Request button showing your test job is running page which is included in Unit tests run within the job. If you click the Details button you should see each step running with its console output. After the job is completed you will receive a notification of whether the check in the workflow passed or failed on the.
Successful or failed test page. Now that your unit test job is complete you will proceed to create the job that runs the integration test. Note: Do not merge this pull request yet. You will reuse this pull request in the rest of this article. Adding an Integration Test Job The process for running integration tests is very similar to the process for running unit tests. What makes this work different is that your integration tests rely on the test database and environment variables. In this section you will set these up and define a job to run the tests. Before you start making changes you need to check the repository's branches again Copy first copy the job into a new job named. Also in the last step of the job .