GitHub

DaffCartStoreCreditTestingDriver

import { DaffCartStoreCreditTestingDriver } from '@daffodil/cart-store-credit/driver/testing'

A basic cart driver that creates mock cart results of different kinds. For testing purposes.

@Injectable()
class DaffCartStoreCreditTestingDriver implements DaffCartStoreCreditDriverInterface {
  apply(): Observable<DaffCartWithStoreCredit>
  remove(): Observable<DaffCartWithStoreCredit>
}

() Methods

apply
Observable<DaffCartWithStoreCredit>

Apply store credit to the cart.

remove
Observable<DaffCartWithStoreCredit>

Remove store credit from the cart.