https://github.com/actionanand/angular-testing
Angular Testing Repo - A complete guide to Angular Unit Testing and E2E Testing
https://github.com/actionanand/angular-testing
angular angular12 jasmine local-server proxy proxy-server testing unit-testing
Last synced: about 1 month ago
JSON representation
Angular Testing Repo - A complete guide to Angular Unit Testing and E2E Testing
- Host: GitHub
- URL: https://github.com/actionanand/angular-testing
- Owner: actionanand
- License: mit
- Created: 2021-06-02T12:02:31.000Z (about 5 years ago)
- Default Branch: main
- Last Pushed: 2021-06-28T16:03:21.000Z (almost 5 years ago)
- Last Synced: 2025-04-02T03:28:40.933Z (about 1 year ago)
- Topics: angular, angular12, jasmine, local-server, proxy, proxy-server, testing, unit-testing
- Language: TypeScript
- Homepage:
- Size: 269 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Angular Testing
This repository is updated to Angular v12, and there is a package-lock.json file available, for avoiding semantic versioning installation issues.
## Installing the Angular CLI
With the following command the angular-cli will be installed globally in your machine:
```bash
npm install -g @angular/cli
```
## How To run this app
Its also possible to install the modules using the following command:
```bash
npm install
```
NPM 5 or above has the big advantage that if you use it you will be installing the exact same dependencies than I installed in my machine, so you wont run into issues caused by semantic versioning updates.
This should take a couple of minutes. If there are issues, please post the complete error message in the Questions section of the course.
## To Run the Development Backend Server
We can start the sample application backend with the following command:
```bash
npm run server
```
This is a small Node REST API server.
## To run the Development UI Server
To run the frontend part of our code, we will use the Angular CLI:
```bash
npm start
```
The application is visible at port 4200: [http://localhost:4200](http://localhost:4200)
## To run test without `hot reloading`
```bash
ng test --no-watch
```
## Other sources
* [Jasmine](https://jasmine.github.io/index.html "Jasmine Official Documents")
* [Angular Official Test Docs](https://angular.io/guide/testing "Angular Official Test Documents")
* [requestAnimationFrame](https://developer.mozilla.org/en-US/docs/Web/API/window/requestAnimationFrame "MDN Web Doc - Window.requestAnimationFrame()")
* [Angular - zone js (GitHub)](https://github.com/angular/angular/tree/master/packages/zone.js)
* [Angular zonejs](https://angular.io/guide/zone)
* [Renaming async to waitForAsync - GitHub](https://github.com/angular/angular/pull/37583 "Renaming async to waitForAsync")