Use basic testing terminology
Identify parts of an Angular app
Discuss the differences between isolated tests and integrated tests and when to use each
Discuss deep vs. shallow testing
Write a unit test in Angular
An isolated test of the smallest unit of code
It should be fast, cheap to write, cover a single state change, assert one thing, avoid crossing process boundaries, and be reliable.
A behavior-driven development framework
Has many built-in utilities for testing
A lightweight server that loads and runs tests in browsers
Arrange - Act - Assert
Mocking is the mechanism of replacing a dependency with a fake piece of code that does less than the original.
Spies are test doubles. A spy can stub any function and tracks calls to it and all arguments.
Class only - no template
Constructed in test
Best for Services and Pipes
Test class with template
Constructed by framework
Mainly used for components and directives
Test a component and all of its nested components, directives
Gives a better idea of how your app will actually run
Can be big and complicated and therefore more brittle
Testing utility that creates an Angular testing module—an @NgModule class—that you configure with the...
...method to produce the module environment for the class you want to test