All Courses Angular.js Tutorials

Angular Testing Masterclass (Angular 15)

Angular Testing Masterclass (Angular 15)

A complete guide to Angular 15 Unit Testing and End-to-End (E2E) Testing, including Testing best practices and CI

What you’ll learn

Angular Testing Masterclass (Angular 15)



  • Code in the GitHub repository with downloadable ZIP files per section



  • Testing Fundamentals



  • Angular Unit Testing Best Practices



  • Angular E2E Testing with Cypress



  • Angular Component and Service Testing



  • Asynchronous Angular Testing with fakeAsync and Async



  • Continuous Integration with TravTesting



    equirements

  • No prior knowledge of Testing is needed

  • Previous knowledge of Angular is important

Description



This Course in a Nutshell

This video course, complete with a running GitHub repository, is a full step-by-step guide to Angular Testing in general. We will take a small sample application that is already completed but has no tests yet.

We are then going to discuss the best approach to test each part of the application, and we are going to



write the tests step-by-step



, explaining



every decision along the way



.









We will start by writing



Unit Tests



for the multiple parts of the application, and then at a later stage, we will learn how to perform End to End (



E2E



) tests.

More than talking about



how



to test, this course will also cover



when and why and



all sorts of stretching best practices.



Course Overview



Starting from scratch, we will introduce



behavior-driven testing concepts



by quickly introducing the main ideas and utilities of the Jasmine Testing framework.

We are then going to introduce some testing best practices, and we are going to talk about



mocks and Jasmine spies



. We will then introduce some of the Angular Testing utilities, such as the Angular TestBed, which we will use to test a couple of simple Angular services.

We will then move on to test a more complex Angular service and talk about Angular HTTP requesTestingng, after which we will cover the testing of Angular components.

We will learn how to test



Angular components



with and without the DOM and what parts of the element to try, and we will also cover in detail asynchronous tests using the



fakeAsync and async



utilities.

We will cover how to test several typical Angular components, such as presentational and innovative or container components, and we will learn how to



mock Angular Observable-based services



.

After unit testing the multiple components of our application, we will create a test suite of



End to End tests using Cypress.

Once we have the tests written for our application, we will deploy them to



Travis CI



and ensure they are triggered with every commit.

At the end of the course, we will generate a test coverage report and discuss some of the metrics.



Table of Contents



This course will go over the following topics:







  • Introduction to the Jasmine testing framework
  • Introduction to Jasmine spies
  • Unit Testing of Simple Angular Services
  • Jasmine testing best practices
  • Introduction to Angular testing utilities
  • Testing of Angular complex services
  • Mocking of Angular HTTP requests
  • Unit Testing of Angular Components
  • Asynchronous Angular Testing with fakeAsync and async
  • Mocking of Observable-based Services
  • Unit Testing of Presentational Components
  • Unit Testing of Smart or Container Components
  • Simulation of user interaction in unit tests
  • End-to-End Angular Testing with Cypress
  • Continuous Integration with Travis CI
  • Angular CLI Test Coverage Reports



What Will You Learn In this Course?

With this course, you will feel comfortable writing Angular tests for multiple types of services and components. You will know not only the numerous Jasmine and Angular testing utilities available, but you will also know



when to use them anTesting



You will be familiar with Angular testing best practices. You will learn how to write practical tests that don’t take much time and contribute significantly to your project’s long-term health.

Look at the course’s free lessons, and please enjoy the system!

Who this course is for:

  • Angular Developers looking for a detailed guide to Angular Unit Testing and End to End Testing

Angular Testing Masterclass (Angular 15)



Jasmine and Karma in an Angular unit test scenario










If the links does not work, contact us we will fix them











Categories

Advertisement