Running Unit Tests This project includes unit tests written using Jasmine and executed with Karma test runner. Follow the steps below to run the unit tests: Prerequisites • Node.js and npm installed on your machine.
Installation
- Clone the repository to your local machine: git clone
- Navigate to the project directory: cd
- Install dependencies: npm install
Running Tests To execute the unit tests, run the following command: ng test This command will build the application and start the Karma test runner to execute the tests in a headless browser. The test results will be displayed in the terminal/command prompt.
Viewing Test Coverage After running the tests, you can view the test coverage report generated. Open the coverage directory and locate the index.html file. Open this file in a web browser to view the test coverage report. open coverage/index.html