GitHub

DaffCustomerTestingDriver

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

import { DaffCustomerTestingDriver } from '@daffodil/customer/driver/testing'
@Injectable()
class DaffCustomerTestingDriver implements DaffCustomerDriverInterface {
  changeEmail(
    email: string
    password: string
  ): Observable<DaffCustomer>
  changePassword(
    oldPassword: string
    newPassword: string
  ): Observable<void>
  get(): Observable<DaffCustomer>
  update(customer: Partial<DaffCustomer>): Observable<DaffCustomer>
}

Properties

Name Type Description
changeEmail Observable<DaffCustomer>

Change the currently logged-in customer's email.

changePassword Observable<void>

Change the currently logged-in customer's password.

get Observable<DaffCustomer>

Get the currently logged-in customer.

update Observable<DaffCustomer>

Update the currently logged-in customer.