15.0.0 • Published 9 months ago

@ngworker/spectacular v15.0.0

Weekly downloads
16
License
MIT
Repository
github
Last release
9 months ago

Spectacular

@ngworker/spectacular

Spectacular Angular integration testing.

Spectacular offers test harnesses for Angular applications and libraries.

Application testing

Spectacular's application testing API configures the Angular testing module and bootstraps a component while ensuring that all application-level hooks are run.

The application test harness is used to test configuration Angular modules, bootstrap listeners, and application initializers.

Public API

Export nameKindDescription
createApplicationHarnessFactory for SpectacularApplicationHarnessBootstrap a Spectacular application with the specified metadata. Useful to test configuration Angular modules, bootstrap listeners, and application initializers.
CreateApplicationHarnessOptionsOptions for createApplicationHarnessApplication harness options.
SpectacularApplicationHarnessInterfaceA harness for testing application-level software artifacts.

Feature testing

Spectacular's feature testing API configures the Angular testing module and sets up a test harness for a routed Angular feature module. It contains a few companion services that wrap Angular's built-in navigation services, but adjusted to the Angular feature module under test.

The feature test harness is used to test routed feature modules and shell modules.

Public API

Export nameKindDescription
createFeatureHarnessFactory for SpectacularFeatureHarnessConfigure SpectacularFeatureTestingModule, bootstrap SpectacularAppComponent and navigate to the default feature route.
CreateFeatureHarnessOptionsOptions for createFeatureHarnessFeature harness options.
SpectacularFeatureHarnessInterfaceA harness for testing an Angular feature module.
SpectacularFeatureTestingModuleOptionsOptions for SpectacularFeatureTestingModuleFeature testing options for SpectacularFeatureTestingModule.withFeature.
SpectacularFeatureTestingModuleAngular testing configuration moduleConfigure the RouterTestingModule and provide Spectactular services for testing feature modules.
SpectacularFeatureTestingRootModuleInternal Angular testing configuration moduleInternal use only. Used by SpectacularFeatureTestingModule.withFeature.
SpectacularFeatureLocationServiceA subset of Angular's Location service adjusted to the Angular feature module under test.
SpectacularFeatureRouterServiceA subset of Angular's Router service adjusted to the Angular feature module under test.

Pipe testing

Spectacular's pipe testing API configures the Angular testing module and sets up a host component for the Angular pipe under test.

Public API

Export nameKindDescription
createPipeHarnessSpectacularPipeHarness factorySet up a host component for the Angular pipe under test.
CreatePipeHarnessOptionsOptions for createPipeHarnessAngular pipe harness options.
SpectacularPipeHarnessInterfaceA harness for testing an Angular pipe.

Shared

Test utilities used by Spectacular's other APIs.

Public API

Export nameKindDescription
SpectacularAppComponentBootstrapped componentThe root component which is bootstrapped for a Spectacular test.
spectacularAppTagStringThe tag name of SpectacularAppComponents DOM element.
15.0.0-alpha.0

9 months ago

15.0.0

9 months ago

14.0.0

10 months ago

14.1.0

10 months ago

14.0.1

10 months ago

13.0.0

10 months ago

0.5.0

2 years ago

0.4.0

2 years ago

0.3.0

2 years ago

0.2.0

3 years ago

0.1.0

3 years ago