randomize IBAN for tests

This commit is contained in:
MS 2021-02-12 21:51:09 +01:00
parent 2bfb7853fd
commit 118975fee3
No known key found for this signature in database
GPG Key ID: 8D526861953F4C0F

View File

@ -252,7 +252,7 @@ export interface SimulateIncomingTransactionRequest {
* data that is required to initialize a new user + Ebics * data that is required to initialize a new user + Ebics
* connection thereof. * connection thereof.
*/ */
class NexusUserBundle { export class NexusUserBundle {
userReq: CreateNexusUserRequest; userReq: CreateNexusUserRequest;
connReq: CreateEbicsBankConnectionRequest; connReq: CreateEbicsBankConnectionRequest;
twg: CreateTalerWireGatewayFacadeRequest; twg: CreateTalerWireGatewayFacadeRequest;
@ -291,13 +291,15 @@ class NexusUserBundle {
* customer, associating their bank account with a Ebics * customer, associating their bank account with a Ebics
* subscriber. * subscriber.
*/ */
class SandboxUserBundle { export class SandboxUserBundle {
ebicsBankAccount: CreateEbicsBankAccountRequest; ebicsBankAccount: CreateEbicsBankAccountRequest;
constructor(salt: string) { constructor(salt: string) {
this.ebicsBankAccount = { this.ebicsBankAccount = {
currency: "EUR", currency: "EUR",
bic: "DEUTDEBB101", // <= FIXME: properly randomize bic: "BELADEBEXXX",
iban: "IBAN", // <= FIXME: properly randomize iban: `DE715001051796${(Math.random() * 100000000)
.toString()
.substring(0, 8)}`,
label: `remote-account-${salt}`, label: `remote-account-${salt}`,
name: `Taler Exchange: ${salt}`, name: `Taler Exchange: ${salt}`,
subscriber: { subscriber: {