import { CommonModule } from '@angular/common' ; import { NgModule , ModuleWithProviders , } from '@angular/core' ; import { DaffCheckoutDriver } from '@daffodil/checkout' ; import { DaffTestingCheckoutService } from './checkout.service' ; @ NgModule ( { imports : [ CommonModule , ] , } ) export class DaffCheckoutTestingDriverModule { static forRoot ( ) { return { ngModule : DaffCheckoutTestingDriverModule , providers : [ { provide : DaffCheckoutDriver , useExisting : DaffTestingCheckoutService , } , ] , } ; } }