From 40279ae7f0520b25f5aecf5b2318a1bb5772c10c Mon Sep 17 00:00:00 2001 From: Sebastian Date: Thu, 19 Jan 2023 16:16:42 -0300 Subject: pretty --- packages/taler-harness/src/bench2.ts | 4 +- packages/taler-harness/src/bench3.ts | 5 +- .../taler-harness/src/benchMerchantIDGenerator.ts | 23 +++--- packages/taler-harness/src/harness/harness.ts | 4 +- .../taler-harness/src/harness/libeufin-apis.ts | 14 +--- packages/taler-harness/src/harness/libeufin.ts | 12 +-- .../taler-harness/src/harness/merchantApiTypes.ts | 1 - packages/taler-harness/src/harness/sync.ts | 2 +- packages/taler-harness/src/import-meta-url.js | 2 +- .../integrationtests/scenario-prompt-payment.ts | 13 ++-- .../integrationtests/test-age-restrictions-peer.ts | 29 ++++--- .../src/integrationtests/test-claim-loop.ts | 13 ++-- .../src/integrationtests/test-denom-unoffered.ts | 88 ++++++++++------------ .../src/integrationtests/test-deposit.ts | 13 ++-- .../taler-harness/src/integrationtests/test-kyc.ts | 30 ++++---- .../test-libeufin-api-bankaccount.ts | 4 +- .../test-libeufin-api-sandbox-camt.ts | 6 +- .../test-libeufin-api-sandbox-transactions.ts | 6 +- .../integrationtests/test-libeufin-bad-gateway.ts | 9 ++- .../src/integrationtests/test-libeufin-basic.ts | 12 ++- .../src/integrationtests/test-libeufin-c5x.ts | 2 +- .../test-libeufin-facade-anastasis.ts | 62 ++++++++------- .../integrationtests/test-libeufin-keyrotation.ts | 4 +- .../test-libeufin-nexus-balance.ts | 2 +- .../test-libeufin-sandbox-wire-transfer-cli.ts | 4 +- .../src/integrationtests/test-libeufin-tutorial.ts | 6 +- .../integrationtests/test-merchant-instances.ts | 2 +- .../integrationtests/test-merchant-longpolling.ts | 13 ++-- .../src/integrationtests/test-payment-abort.ts | 10 ++- .../integrationtests/test-payment-forgettable.ts | 8 +- .../src/integrationtests/test-payment-multiple.ts | 6 +- .../src/integrationtests/test-payment-transient.ts | 14 +--- .../src/integrationtests/test-payment-zero.ts | 8 +- .../src/integrationtests/test-payment.ts | 8 +- .../src/integrationtests/test-peer-to-peer-pull.ts | 2 +- .../src/integrationtests/test-peer-to-peer-push.ts | 19 ++--- .../src/integrationtests/test-refund.ts | 9 ++- .../test-timetravel-autorefresh.ts | 2 +- .../src/integrationtests/test-wallet-balance.ts | 4 +- .../src/integrationtests/test-wallet-dbless.ts | 4 +- 40 files changed, 243 insertions(+), 236 deletions(-) diff --git a/packages/taler-harness/src/bench2.ts b/packages/taler-harness/src/bench2.ts index 196737436..9fa5d7caf 100644 --- a/packages/taler-harness/src/bench2.ts +++ b/packages/taler-harness/src/bench2.ts @@ -49,7 +49,9 @@ export async function runBench2(configJson: any): Promise { // Validate the configuration file for this benchmark. const benchConf = codecForBench2Config().decode(configJson); const curr = benchConf.currency; - const cryptoDisp = new CryptoDispatcher(new SynchronousCryptoWorkerFactoryNode()); + const cryptoDisp = new CryptoDispatcher( + new SynchronousCryptoWorkerFactoryNode(), + ); const cryptoApi = cryptoDisp.cryptoApi; const http = new NodeHttpLib(); diff --git a/packages/taler-harness/src/bench3.ts b/packages/taler-harness/src/bench3.ts index 6041c525c..9679f05a6 100644 --- a/packages/taler-harness/src/bench3.ts +++ b/packages/taler-harness/src/bench3.ts @@ -59,7 +59,10 @@ export async function runBench3(configJson: any): Promise { const withdrawAmount = (numDeposits + 1) * 10; - const IDGenerator = benchMerchantIDGenerator(b3conf.randomAlg, b3conf.numMerchants ?? 100); + const IDGenerator = benchMerchantIDGenerator( + b3conf.randomAlg, + b3conf.numMerchants ?? 100, + ); logger.info( `Starting Benchmark iterations=${numIter} deposits=${numDeposits} with ${b3conf.randomAlg} merchant selection`, diff --git a/packages/taler-harness/src/benchMerchantIDGenerator.ts b/packages/taler-harness/src/benchMerchantIDGenerator.ts index b83c12bb8..89b26dc81 100644 --- a/packages/taler-harness/src/benchMerchantIDGenerator.ts +++ b/packages/taler-harness/src/benchMerchantIDGenerator.ts @@ -16,16 +16,15 @@ @author: Boss Marco */ -const getRandomInt = function(max: number) { +const getRandomInt = function (max: number) { return Math.floor(Math.random() * max); -} +}; abstract class BenchMerchantIDGenerator { - abstract getRandomMerchantID(): number + abstract getRandomMerchantID(): number; } class ZipfGenerator extends BenchMerchantIDGenerator { - weights: number[]; total_weight: number; @@ -33,10 +32,10 @@ class ZipfGenerator extends BenchMerchantIDGenerator { super(); this.weights = new Array(numMerchants); for (var i = 0; i < this.weights.length; i++) { - /* we use integers (floor), make sure we have big enough values + /* we use integers (floor), make sure we have big enough values * by multiplying with * numMerchants again */ - this.weights[i] = Math.floor((numMerchants/(i+1)) * numMerchants); + this.weights[i] = Math.floor((numMerchants / (i + 1)) * numMerchants); } this.total_weight = this.weights.reduce((p, n) => p + n); } @@ -48,7 +47,7 @@ class ZipfGenerator extends BenchMerchantIDGenerator { for (var i = 0; i < this.weights.length; i++) { current += this.weights[i]; if (random <= current) { - return i+1; + return i + 1; } } @@ -58,12 +57,11 @@ class ZipfGenerator extends BenchMerchantIDGenerator { } class RandomGenerator extends BenchMerchantIDGenerator { - - max: number + max: number; constructor(numMerchants: number) { super(); - this.max = numMerchants + this.max = numMerchants; } getRandomMerchantID() { @@ -71,7 +69,10 @@ class RandomGenerator extends BenchMerchantIDGenerator { } } -export default function(type: string, maxID: number): BenchMerchantIDGenerator { +export default function ( + type: string, + maxID: number, +): BenchMerchantIDGenerator { switch (type) { case "zipf": return new ZipfGenerator(maxID); diff --git a/packages/taler-harness/src/harness/harness.ts b/packages/taler-harness/src/harness/harness.ts index 5b72cbc06..134709541 100644 --- a/packages/taler-harness/src/harness/harness.ts +++ b/packages/taler-harness/src/harness/harness.ts @@ -1086,7 +1086,9 @@ export class ExchangeService implements ExchangeServiceInterface { * The modified exchange configuration will then be written to the * file system. */ - async modifyConfig(f: (config: Configuration) => Promise): Promise { + async modifyConfig( + f: (config: Configuration) => Promise, + ): Promise { const config = Configuration.load(this.configFilename); await f(config); config.write(this.configFilename); diff --git a/packages/taler-harness/src/harness/libeufin-apis.ts b/packages/taler-harness/src/harness/libeufin-apis.ts index 2f8e53cc9..a6abe3466 100644 --- a/packages/taler-harness/src/harness/libeufin-apis.ts +++ b/packages/taler-harness/src/harness/libeufin-apis.ts @@ -197,16 +197,13 @@ export namespace LibeufinSandboxApi { username: string, password: string, libeufinSandboxService: LibeufinSandboxServiceInterface, - iban: string|null = null, + iban: string | null = null, ) { - let url = new URL( - "testing/register", - libeufinSandboxService.baseUrl - ); + let url = new URL("testing/register", libeufinSandboxService.baseUrl); await axios.post(url.href, { username: username, password: password, - iban: iban + iban: iban, }); } // Need /demobanks/$id as the base URL @@ -218,10 +215,7 @@ export namespace LibeufinSandboxApi { password: string = "secret", ) { // baseUrl should already be pointed to one demobank. - let url = new URL( - "ebics/subscribers", - libeufinSandboxService.baseUrl - ); + let url = new URL("ebics/subscribers", libeufinSandboxService.baseUrl); await axios.post( url.href, { diff --git a/packages/taler-harness/src/harness/libeufin.ts b/packages/taler-harness/src/harness/libeufin.ts index 638c8ed90..05ca4d751 100644 --- a/packages/taler-harness/src/harness/libeufin.ts +++ b/packages/taler-harness/src/harness/libeufin.ts @@ -56,7 +56,6 @@ import { CreateNexusUserRequest, } from "../harness/libeufin-apis.js"; - const logger = new Logger("libeufin.ts"); export { LibeufinSandboxApi, LibeufinNexusApi }; @@ -451,7 +450,10 @@ export class LibeufinCli { ); } - async registerBankCustomer(username: string, password: string): Promise { + async registerBankCustomer( + username: string, + password: string, + ): Promise { const stdout = await sh( this.globalTestState, "libeufin-cli-registercustomer", @@ -817,7 +819,7 @@ export async function launchLibeufinServices( await libeufinNexus.start(); await libeufinNexus.pingUntilAvailable(); console.log("Libeufin services launched!"); - + for (let sb of sandboxUserBundle) { await LibeufinSandboxApi.createEbicsHost( libeufinSandbox, @@ -830,12 +832,12 @@ export async function launchLibeufinServices( await LibeufinSandboxApi.createDemobankAccount( sb.ebicsBankAccount.label, "password-unused", - { baseUrl: libeufinSandbox.baseUrl + "/demobanks/default/access-api/" } + { baseUrl: libeufinSandbox.baseUrl + "/demobanks/default/access-api/" }, ); await LibeufinSandboxApi.createDemobankEbicsSubscriber( sb.ebicsBankAccount.subscriber, sb.ebicsBankAccount.label, - { baseUrl: libeufinSandbox.baseUrl + "/demobanks/default/" } + { baseUrl: libeufinSandbox.baseUrl + "/demobanks/default/" }, ); } console.log("Sandbox user(s) / account(s) / subscriber(s): created"); diff --git a/packages/taler-harness/src/harness/merchantApiTypes.ts b/packages/taler-harness/src/harness/merchantApiTypes.ts index 2a59b0160..1985e9150 100644 --- a/packages/taler-harness/src/harness/merchantApiTypes.ts +++ b/packages/taler-harness/src/harness/merchantApiTypes.ts @@ -82,7 +82,6 @@ export const codecForPostOrderResponse = (): Codec => .property("token", codecOptional(codecForString())) .build("PostOrderResponse"); - export const codecForRefundDetails = (): Codec => buildCodecForObject() .property("reason", codecForString()) diff --git a/packages/taler-harness/src/harness/sync.ts b/packages/taler-harness/src/harness/sync.ts index a9e8de412..64c9acaef 100644 --- a/packages/taler-harness/src/harness/sync.ts +++ b/packages/taler-harness/src/harness/sync.ts @@ -115,5 +115,5 @@ export class SyncService { private globalState: GlobalTestState, private syncConfig: SyncConfig, private configFilename: string, - ) { } + ) {} } diff --git a/packages/taler-harness/src/import-meta-url.js b/packages/taler-harness/src/import-meta-url.js index b7def9b07..c0e657160 100644 --- a/packages/taler-harness/src/import-meta-url.js +++ b/packages/taler-harness/src/import-meta-url.js @@ -1,2 +1,2 @@ // Helper to make 'import.meta.url' available in esbuild-bundled code as well. -export const import_meta_url = require('url').pathToFileURL(__filename); +export const import_meta_url = require("url").pathToFileURL(__filename); diff --git a/packages/taler-harness/src/integrationtests/scenario-prompt-payment.ts b/packages/taler-harness/src/integrationtests/scenario-prompt-payment.ts index ea05de8e9..7177a017c 100644 --- a/packages/taler-harness/src/integrationtests/scenario-prompt-payment.ts +++ b/packages/taler-harness/src/integrationtests/scenario-prompt-payment.ts @@ -18,7 +18,10 @@ * Imports. */ import { GlobalTestState, MerchantPrivateApi } from "../harness/harness.js"; -import { createSimpleTestkudosEnvironment, withdrawViaBank } from "../harness/helpers.js"; +import { + createSimpleTestkudosEnvironment, + withdrawViaBank, +} from "../harness/helpers.js"; /** * Run test for basic, bank-integrated withdrawal. @@ -26,12 +29,8 @@ import { createSimpleTestkudosEnvironment, withdrawViaBank } from "../harness/he export async function runPromptPaymentScenario(t: GlobalTestState) { // Set up test environment - const { - wallet, - bank, - exchange, - merchant, - } = await createSimpleTestkudosEnvironment(t); + const { wallet, bank, exchange, merchant } = + await createSimpleTestkudosEnvironment(t); // Withdraw digital cash into the wallet. diff --git a/packages/taler-harness/src/integrationtests/test-age-restrictions-peer.ts b/packages/taler-harness/src/integrationtests/test-age-restrictions-peer.ts index af5b4df52..1d8986436 100644 --- a/packages/taler-harness/src/integrationtests/test-age-restrictions-peer.ts +++ b/packages/taler-harness/src/integrationtests/test-age-restrictions-peer.ts @@ -18,7 +18,10 @@ * Imports. */ import { AbsoluteTime, Duration } from "@gnu-taler/taler-util"; -import { getDefaultNodeWallet2, WalletApiOperation } from "@gnu-taler/taler-wallet-core"; +import { + getDefaultNodeWallet2, + WalletApiOperation, +} from "@gnu-taler/taler-wallet-core"; import { defaultCoinConfig } from "../harness/denomStructures.js"; import { GlobalTestState, WalletCli } from "../harness/harness.js"; import { @@ -67,19 +70,25 @@ export async function runAgeRestrictionsPeerTest(t: GlobalTestState) { ), ); - const initResp = await wallet.client.call(WalletApiOperation.InitiatePeerPushPayment, { - partialContractTerms: { - summary: "Hello, World", - amount: "TESTKUDOS:1", - purse_expiration, + const initResp = await wallet.client.call( + WalletApiOperation.InitiatePeerPushPayment, + { + partialContractTerms: { + summary: "Hello, World", + amount: "TESTKUDOS:1", + purse_expiration, + }, }, - }); + ); await wallet.runUntilDone(); - const checkResp = await walletTwo.client.call(WalletApiOperation.CheckPeerPushPayment, { - talerUri: initResp.talerUri, - }); + const checkResp = await walletTwo.client.call( + WalletApiOperation.CheckPeerPushPayment, + { + talerUri: initResp.talerUri, + }, + ); await walletTwo.client.call(WalletApiOperation.AcceptPeerPushPayment, { peerPushPaymentIncomingId: checkResp.peerPushPaymentIncomingId, diff --git a/packages/taler-harness/src/integrationtests/test-claim-loop.ts b/packages/taler-harness/src/integrationtests/test-claim-loop.ts index a509e3b19..921391283 100644 --- a/packages/taler-harness/src/integrationtests/test-claim-loop.ts +++ b/packages/taler-harness/src/integrationtests/test-claim-loop.ts @@ -18,7 +18,10 @@ * Imports. */ import { GlobalTestState, MerchantPrivateApi } from "../harness/harness.js"; -import { createSimpleTestkudosEnvironment, withdrawViaBank } from "../harness/helpers.js"; +import { + createSimpleTestkudosEnvironment, + withdrawViaBank, +} from "../harness/helpers.js"; import { URL } from "url"; import { WalletApiOperation } from "@gnu-taler/taler-wallet-core"; @@ -31,12 +34,8 @@ import { WalletApiOperation } from "@gnu-taler/taler-wallet-core"; export async function runClaimLoopTest(t: GlobalTestState) { // Set up test environment - const { - wallet, - bank, - exchange, - merchant, - } = await createSimpleTestkudosEnvironment(t); + const { wallet, bank, exchange, merchant } = + await createSimpleTestkudosEnvironment(t); await withdrawViaBank(t, { wallet, bank, exchange, amount: "TESTKUDOS:20" }); diff --git a/packages/taler-harness/src/integrationtests/test-denom-unoffered.ts b/packages/taler-harness/src/integrationtests/test-denom-unoffered.ts index 5b3aec551..27c336ea6 100644 --- a/packages/taler-harness/src/integrationtests/test-denom-unoffered.ts +++ b/packages/taler-harness/src/integrationtests/test-denom-unoffered.ts @@ -55,54 +55,46 @@ export async function runDenomUnofferedTest(t: GlobalTestState) { fulfillment_url: "taler://fulfillment-success/thx", }; - const orderResp = await MerchantPrivateApi.createOrder( - merchant, - "default", - { - order: order, - }, - ); - - let orderStatus = await MerchantPrivateApi.queryPrivateOrderStatus( - merchant, - { - orderId: orderResp.order_id, - }, - ); - - t.assertTrue(orderStatus.order_status === "unpaid"); - - // Make wallet pay for the order - - const preparePayResult = await wallet.client.call( - WalletApiOperation.PreparePayForUri, - { - talerPayUri: orderStatus.taler_pay_uri, - }, - ); - - t.assertTrue( - preparePayResult.status === PreparePayResultType.PaymentPossible, - ); - - const confirmResp = await wallet.client.call(WalletApiOperation.ConfirmPay, { - proposalId: preparePayResult.proposalId, - }); - - const tx = await wallet.client.call(WalletApiOperation.GetTransactionById, { - transactionId: confirmResp.transactionId, - }); - - t.assertTrue( - tx.error?.code === TalerErrorCode.WALLET_UNEXPECTED_REQUEST_ERROR - ); - - const merchantErrorCode = ((tx.error as any).errorResponse as any) - .code; - t.assertDeepEqual( - merchantErrorCode, - TalerErrorCode.MERCHANT_POST_ORDERS_ID_PAY_DENOMINATION_KEY_NOT_FOUND, - ); + const orderResp = await MerchantPrivateApi.createOrder(merchant, "default", { + order: order, + }); + + let orderStatus = await MerchantPrivateApi.queryPrivateOrderStatus(merchant, { + orderId: orderResp.order_id, + }); + + t.assertTrue(orderStatus.order_status === "unpaid"); + + // Make wallet pay for the order + + const preparePayResult = await wallet.client.call( + WalletApiOperation.PreparePayForUri, + { + talerPayUri: orderStatus.taler_pay_uri, + }, + ); + + t.assertTrue( + preparePayResult.status === PreparePayResultType.PaymentPossible, + ); + + const confirmResp = await wallet.client.call(WalletApiOperation.ConfirmPay, { + proposalId: preparePayResult.proposalId, + }); + + const tx = await wallet.client.call(WalletApiOperation.GetTransactionById, { + transactionId: confirmResp.transactionId, + }); + + t.assertTrue( + tx.error?.code === TalerErrorCode.WALLET_UNEXPECTED_REQUEST_ERROR, + ); + + const merchantErrorCode = ((tx.error as any).errorResponse as any).code; + t.assertDeepEqual( + merchantErrorCode, + TalerErrorCode.MERCHANT_POST_ORDERS_ID_PAY_DENOMINATION_KEY_NOT_FOUND, + ); await wallet.client.call(WalletApiOperation.AddExchange, { exchangeBaseUrl: exchange.baseUrl, diff --git a/packages/taler-harness/src/integrationtests/test-deposit.ts b/packages/taler-harness/src/integrationtests/test-deposit.ts index e4ca08789..a66893fa7 100644 --- a/packages/taler-harness/src/integrationtests/test-deposit.ts +++ b/packages/taler-harness/src/integrationtests/test-deposit.ts @@ -19,7 +19,10 @@ */ import { WalletApiOperation } from "@gnu-taler/taler-wallet-core"; import { GlobalTestState, getPayto } from "../harness/harness.js"; -import { createSimpleTestkudosEnvironment, withdrawViaBank } from "../harness/helpers.js"; +import { + createSimpleTestkudosEnvironment, + withdrawViaBank, +} from "../harness/helpers.js"; /** * Run test for basic, bank-integrated withdrawal and payment. @@ -27,12 +30,8 @@ import { createSimpleTestkudosEnvironment, withdrawViaBank } from "../harness/he export async function runDepositTest(t: GlobalTestState) { // Set up test environment - const { - wallet, - bank, - exchange, - merchant, - } = await createSimpleTestkudosEnvironment(t); + const { wallet, bank, exchange, merchant } = + await createSimpleTestkudosEnvironment(t); // Withdraw digital cash into the wallet. diff --git a/packages/taler-harness/src/integrationtests/test-kyc.ts b/packages/taler-harness/src/integrationtests/test-kyc.ts index c59b2e8df..c652c86fa 100644 --- a/packages/taler-harness/src/integrationtests/test-kyc.ts +++ b/packages/taler-harness/src/integrationtests/test-kyc.ts @@ -119,26 +119,26 @@ export async function createKycTestkudosEnvironment( "kyc_oauth2_info_url", "http://localhost:6666/oauth/v2/login", ); + config.setString(myprov, "kyc_oauth2_client_id", "taler-exchange"); + config.setString(myprov, "kyc_oauth2_client_secret", "exchange-secret"); + config.setString(myprov, "kyc_oauth2_post_url", "https://taler.com"); + config.setString( - myprov, - "kyc_oauth2_client_id", - "taler-exchange", + "kyc-legitimization-withdraw1", + "operation_type", + "withdraw", ); config.setString( - myprov, - "kyc_oauth2_client_secret", - "exchange-secret", + "kyc-legitimization-withdraw1", + "required_checks", + "dummy1", ); + config.setString("kyc-legitimization-withdraw1", "timeframe", "1d"); config.setString( - myprov, - "kyc_oauth2_post_url", - "https://taler.com", + "kyc-legitimization-withdraw1", + "threshold", + "TESTKUDOS:5", ); - - config.setString("kyc-legitimization-withdraw1", "operation_type", "withdraw"); - config.setString("kyc-legitimization-withdraw1", "required_checks", "dummy1"); - config.setString("kyc-legitimization-withdraw1", "timeframe", "1d"); - config.setString("kyc-legitimization-withdraw1", "threshold", "TESTKUDOS:5"); }); await exchange.start(); @@ -203,4 +203,4 @@ export async function runKycTest(t: GlobalTestState) { runKycTest.suites = ["wallet"]; // See bugs.taler.net/n/7599 -runKycTest.experimental = true; \ No newline at end of file +runKycTest.experimental = true; diff --git a/packages/taler-harness/src/integrationtests/test-libeufin-api-bankaccount.ts b/packages/taler-harness/src/integrationtests/test-libeufin-api-bankaccount.ts index 6f3e5038d..a5396a472 100644 --- a/packages/taler-harness/src/integrationtests/test-libeufin-api-bankaccount.ts +++ b/packages/taler-harness/src/integrationtests/test-libeufin-api-bankaccount.ts @@ -53,7 +53,7 @@ export async function runLibeufinApiBankaccountTest(t: GlobalTestState) { "mock", "password-unused", { baseUrl: sandbox.baseUrl + "/demobanks/default/access-api/" }, - "DE71500105179674997361" + "DE71500105179674997361", ); await LibeufinSandboxApi.createDemobankEbicsSubscriber( { @@ -62,7 +62,7 @@ export async function runLibeufinApiBankaccountTest(t: GlobalTestState) { userID: "mock", }, "mock", - { baseUrl: sandbox.baseUrl + "/demobanks/default/" } + { baseUrl: sandbox.baseUrl + "/demobanks/default/" }, ); await LibeufinNexusApi.createEbicsBankConnection(nexus, { name: "bankaccount-api-test-connection", diff --git a/packages/taler-harness/src/integrationtests/test-libeufin-api-sandbox-camt.ts b/packages/taler-harness/src/integrationtests/test-libeufin-api-sandbox-camt.ts index cb85c1ffc..239bab334 100644 --- a/packages/taler-harness/src/integrationtests/test-libeufin-api-sandbox-camt.ts +++ b/packages/taler-harness/src/integrationtests/test-libeufin-api-sandbox-camt.ts @@ -33,16 +33,16 @@ export async function runLibeufinApiSandboxCamtTest(t: GlobalTestState) { }); await sandbox.start(); await sandbox.pingUntilAvailable(); - + await LibeufinSandboxApi.createDemobankAccount( "mock-account-0", "password-unused", - { baseUrl: sandbox.baseUrl + "/demobanks/default/access-api/" } + { baseUrl: sandbox.baseUrl + "/demobanks/default/access-api/" }, ); await LibeufinSandboxApi.createDemobankAccount( "mock-account-1", "password-unused", - { baseUrl: sandbox.baseUrl + "/demobanks/default/access-api/" } + { baseUrl: sandbox.baseUrl + "/demobanks/default/access-api/" }, ); await sandbox.makeTransaction( "mock-account-0", diff --git a/packages/taler-harness/src/integrationtests/test-libeufin-api-sandbox-transactions.ts b/packages/taler-harness/src/integrationtests/test-libeufin-api-sandbox-transactions.ts index 1d41a614c..f1ff69a6d 100644 --- a/packages/taler-harness/src/integrationtests/test-libeufin-api-sandbox-transactions.ts +++ b/packages/taler-harness/src/integrationtests/test-libeufin-api-sandbox-transactions.ts @@ -36,7 +36,7 @@ export async function runLibeufinApiSandboxTransactionsTest( "mock-account", "password-unused", { baseUrl: sandbox.baseUrl + "/demobanks/default/access-api/" }, - "DE71500105179674997361" + "DE71500105179674997361", ); await LibeufinSandboxApi.simulateIncomingTransaction( sandbox, @@ -46,7 +46,7 @@ export async function runLibeufinApiSandboxTransactionsTest( debtorBic: "BELADEBEXXX", debtorName: "mock2", subject: "mock subject", - amount: "EUR:1" + amount: "EUR:1", }, ); await LibeufinSandboxApi.simulateIncomingTransaction( @@ -57,7 +57,7 @@ export async function runLibeufinApiSandboxTransactionsTest( debtorBic: "BELADEBEXXX", debtorName: "mock2", subject: "mock subject 2", - amount: "EUR:1.1" + amount: "EUR:1.1", }, ); let ret = await LibeufinSandboxApi.getAccountInfoWithBalance( diff --git a/packages/taler-harness/src/integrationtests/test-libeufin-bad-gateway.ts b/packages/taler-harness/src/integrationtests/test-libeufin-bad-gateway.ts index 53aacca84..1187d923b 100644 --- a/packages/taler-harness/src/integrationtests/test-libeufin-bad-gateway.ts +++ b/packages/taler-harness/src/integrationtests/test-libeufin-bad-gateway.ts @@ -34,7 +34,8 @@ export async function runLibeufinBadGatewayTest(t: GlobalTestState) { * User saltetd "01" */ const user01nexus = new NexusUserBundle( - "01", "http://localhost:5010/not-found", // the EBICS endpoint at Sandbox + "01", + "http://localhost:5010/not-found", // the EBICS endpoint at Sandbox ); // Start Nexus @@ -52,11 +53,11 @@ export async function runLibeufinBadGatewayTest(t: GlobalTestState) { }); await libeufinSandbox.start(); await libeufinSandbox.pingUntilAvailable(); - + // Connecting to a non-existent Sandbox endpoint. await LibeufinNexusApi.createEbicsBankConnection( libeufinNexus, - user01nexus.connReq + user01nexus.connReq, ); // 502 Bad Gateway expected. @@ -65,7 +66,7 @@ export async function runLibeufinBadGatewayTest(t: GlobalTestState) { libeufinNexus, user01nexus.connReq.name, ); - } catch(e: any) { + } catch (e: any) { t.assertTrue(e.response.status == 502); return; } diff --git a/packages/taler-harness/src/integrationtests/test-libeufin-basic.ts b/packages/taler-harness/src/integrationtests/test-libeufin-basic.ts index 0b7d3df09..a58429245 100644 --- a/packages/taler-harness/src/integrationtests/test-libeufin-basic.ts +++ b/packages/taler-harness/src/integrationtests/test-libeufin-basic.ts @@ -17,7 +17,11 @@ /** * Imports. */ -import { AbsoluteTime, MerchantContractTerms, Duration } from "@gnu-taler/taler-util"; +import { + AbsoluteTime, + MerchantContractTerms, + Duration, +} from "@gnu-taler/taler-util"; import { WalletApiOperation, HarnessExchangeBankAccount, @@ -85,7 +89,7 @@ export async function createLibeufinTestEnvironment( "exchangeacct", "password-unused", { baseUrl: libeufinSandbox.baseUrl + "/demobanks/default/access-api/" }, - exchangeIban + exchangeIban, ); await LibeufinSandboxApi.createDemobankEbicsSubscriber( { @@ -94,14 +98,14 @@ export async function createLibeufinTestEnvironment( userID: "user01", }, "exchangeacct", - { baseUrl: libeufinSandbox.baseUrl + "/demobanks/default/" } + { baseUrl: libeufinSandbox.baseUrl + "/demobanks/default/" }, ); await LibeufinSandboxApi.createDemobankAccount( "merchantacct", "password-unused", { baseUrl: libeufinSandbox.baseUrl + "/demobanks/default/access-api/" }, - merchantIban + merchantIban, ); await LibeufinSandboxApi.createDemobankEbicsSubscriber( { diff --git a/packages/taler-harness/src/integrationtests/test-libeufin-c5x.ts b/packages/taler-harness/src/integrationtests/test-libeufin-c5x.ts index 2ba29656a..c6dfca99b 100644 --- a/packages/taler-harness/src/integrationtests/test-libeufin-c5x.ts +++ b/packages/taler-harness/src/integrationtests/test-libeufin-c5x.ts @@ -113,7 +113,7 @@ export async function runLibeufinC5xTest(t: GlobalTestState) { /** * A statement should still account zero payments because - * so far the payment made before is still pending. + * so far the payment made before is still pending. */ expectZero = await LibeufinNexusApi.fetchTransactions( libeufinServices.libeufinNexus, diff --git a/packages/taler-harness/src/integrationtests/test-libeufin-facade-anastasis.ts b/packages/taler-harness/src/integrationtests/test-libeufin-facade-anastasis.ts index ae83738e2..10c73fed5 100644 --- a/packages/taler-harness/src/integrationtests/test-libeufin-facade-anastasis.ts +++ b/packages/taler-harness/src/integrationtests/test-libeufin-facade-anastasis.ts @@ -52,7 +52,9 @@ export async function runLibeufinAnastasisFacadeTest(t: GlobalTestState) { libeufinServices.libeufinNexus, ); // check that original facade shows up. - t.assertTrue(resp.data["facades"][0]["name"] == user01nexus.anastasisReq["name"]); + t.assertTrue( + resp.data["facades"][0]["name"] == user01nexus.anastasisReq["name"], + ); const anastasisBaseUrl: string = resp.data["facades"][0]["baseUrl"]; t.assertTrue(typeof anastasisBaseUrl === "string"); t.assertTrue(anastasisBaseUrl.startsWith("http://")); @@ -63,23 +65,23 @@ export async function runLibeufinAnastasisFacadeTest(t: GlobalTestState) { user01nexus.localAccountName, ); - await LibeufinNexusApi.postPermission( - libeufinServices.libeufinNexus, { - action: "grant", - permission: { - subjectId: user01nexus.userReq.username, - subjectType: "user", - resourceType: "facade", - resourceId: user01nexus.anastasisReq.name, - permissionName: "facade.anastasis.history", - }, - } - ); + await LibeufinNexusApi.postPermission(libeufinServices.libeufinNexus, { + action: "grant", + permission: { + subjectId: user01nexus.userReq.username, + subjectType: "user", + resourceType: "facade", + resourceId: user01nexus.anastasisReq.name, + permissionName: "facade.anastasis.history", + }, + }); // check if empty. let txsEmpty = await LibeufinNexusApi.getAnastasisTransactions( libeufinServices.libeufinNexus, - anastasisBaseUrl, {delta: 5}) + anastasisBaseUrl, + { delta: 5 }, + ); t.assertTrue(txsEmpty.data.incoming_transactions.length == 0); @@ -93,7 +95,7 @@ export async function runLibeufinAnastasisFacadeTest(t: GlobalTestState) { subject: "Anastasis donation", amount: "EUR:3", // Sandbox takes currency from its 'config' }, - ) + ); LibeufinSandboxApi.simulateIncomingTransaction( libeufinServices.libeufinSandbox, @@ -105,7 +107,7 @@ export async function runLibeufinAnastasisFacadeTest(t: GlobalTestState) { subject: "another Anastasis donation", amount: "EUR:1", // Sandbox takes currency from its "config" }, - ) + ); await LibeufinNexusApi.fetchTransactions( libeufinServices.libeufinNexus, @@ -115,18 +117,24 @@ export async function runLibeufinAnastasisFacadeTest(t: GlobalTestState) { let txs = await LibeufinNexusApi.getAnastasisTransactions( libeufinServices.libeufinNexus, anastasisBaseUrl, - {delta: 5}, + { delta: 5 }, user01nexus.userReq.username, user01nexus.userReq.password, ); // check the two payments show up - let txsList = txs.data.incoming_transactions + let txsList = txs.data.incoming_transactions; t.assertTrue(txsList.length == 2); - t.assertTrue([txsList[0].subject, txsList[1].subject].includes("Anastasis donation")); - t.assertTrue([txsList[0].subject, txsList[1].subject].includes("another Anastasis donation")); - t.assertTrue(txsList[0].row_id == 1) - t.assertTrue(txsList[1].row_id == 2) + t.assertTrue( + [txsList[0].subject, txsList[1].subject].includes("Anastasis donation"), + ); + t.assertTrue( + [txsList[0].subject, txsList[1].subject].includes( + "another Anastasis donation", + ), + ); + t.assertTrue(txsList[0].row_id == 1); + t.assertTrue(txsList[1].row_id == 2); LibeufinSandboxApi.simulateIncomingTransaction( libeufinServices.libeufinSandbox, @@ -138,7 +146,7 @@ export async function runLibeufinAnastasisFacadeTest(t: GlobalTestState) { subject: "last Anastasis donation", amount: "EUR:10.10", // Sandbox takes currency from its "config" }, - ) + ); await LibeufinNexusApi.fetchTransactions( libeufinServices.libeufinNexus, @@ -148,16 +156,18 @@ export async function runLibeufinAnastasisFacadeTest(t: GlobalTestState) { let txsLast = await LibeufinNexusApi.getAnastasisTransactions( libeufinServices.libeufinNexus, anastasisBaseUrl, - {delta: 5, start: 2}, + { delta: 5, start: 2 }, user01nexus.userReq.username, user01nexus.userReq.password, ); - console.log(txsLast.data.incoming_transactions[0].subject == "last Anastasis donation"); + console.log( + txsLast.data.incoming_transactions[0].subject == "last Anastasis donation", + ); let txsReverse = await LibeufinNexusApi.getAnastasisTransactions( libeufinServices.libeufinNexus, anastasisBaseUrl, - {delta: -5, start: 4}, + { delta: -5, start: 4 }, user01nexus.userReq.username, user01nexus.userReq.password, ); diff --git a/packages/taler-harness/src/integrationtests/test-libeufin-keyrotation.ts b/packages/taler-harness/src/integrationtests/test-libeufin-keyrotation.ts index 21bf07de2..c4a491037 100644 --- a/packages/taler-harness/src/integrationtests/test-libeufin-keyrotation.ts +++ b/packages/taler-harness/src/integrationtests/test-libeufin-keyrotation.ts @@ -43,7 +43,9 @@ export async function runLibeufinKeyrotationTest(t: GlobalTestState) { * Launch Sandbox and Nexus. */ const libeufinServices = await launchLibeufinServices( - t, [user01nexus], [user01sandbox], + t, + [user01nexus], + [user01sandbox], ); await LibeufinNexusApi.fetchTransactions( diff --git a/packages/taler-harness/src/integrationtests/test-libeufin-nexus-balance.ts b/packages/taler-harness/src/integrationtests/test-libeufin-nexus-balance.ts index 850b0f1d9..5c10c029e 100644 --- a/packages/taler-harness/src/integrationtests/test-libeufin-nexus-balance.ts +++ b/packages/taler-harness/src/integrationtests/test-libeufin-nexus-balance.ts @@ -23,7 +23,7 @@ import { NexusUserBundle, launchLibeufinServices, LibeufinNexusApi, - LibeufinCli + LibeufinCli, } from "../harness/libeufin.js"; /** diff --git a/packages/taler-harness/src/integrationtests/test-libeufin-sandbox-wire-transfer-cli.ts b/packages/taler-harness/src/integrationtests/test-libeufin-sandbox-wire-transfer-cli.ts index e56cb3d68..e6b074d3f 100644 --- a/packages/taler-harness/src/integrationtests/test-libeufin-sandbox-wire-transfer-cli.ts +++ b/packages/taler-harness/src/integrationtests/test-libeufin-sandbox-wire-transfer-cli.ts @@ -36,13 +36,13 @@ export async function runLibeufinSandboxWireTransferCliTest( "mock-account", "password-unused", { baseUrl: sandbox.baseUrl + "/demobanks/default/access-api/" }, - "DE71500105179674997361" + "DE71500105179674997361", ); await LibeufinSandboxApi.createDemobankAccount( "mock-account-2", "password-unused", { baseUrl: sandbox.baseUrl + "/demobanks/default/access-api/" }, - "DE71500105179674997364" + "DE71500105179674997364", ); await sandbox.makeTransaction( diff --git a/packages/taler-harness/src/integrationtests/test-libeufin-tutorial.ts b/packages/taler-harness/src/integrationtests/test-libeufin-tutorial.ts index 7bc067cfe..496b65ee3 100644 --- a/packages/taler-harness/src/integrationtests/test-libeufin-tutorial.ts +++ b/packages/taler-harness/src/integrationtests/test-libeufin-tutorial.ts @@ -101,8 +101,10 @@ export async function runLibeufinTutorialTest(t: GlobalTestState) { }; await libeufinCli.importBankAccount(bankAccountImportDetails); - await libeufinSandbox.c53tick() - await libeufinCli.fetchTransactions(bankAccountImportDetails.nexusBankAccountName); + await libeufinSandbox.c53tick(); + await libeufinCli.fetchTransactions( + bankAccountImportDetails.nexusBankAccountName, + ); await libeufinCli.transactions(bankAccountImportDetails.nexusBankAccountName); const paymentDetails = { diff --git a/packages/taler-harness/src/integrationtests/test-merchant-instances.ts b/packages/taler-harness/src/integrationtests/test-merchant-instances.ts index 3efe83241..78626ea3d 100644 --- a/packages/taler-harness/src/integrationtests/test-merchant-instances.ts +++ b/packages/taler-harness/src/integrationtests/test-merchant-instances.ts @@ -26,7 +26,7 @@ import { MerchantApiClient, MerchantService, setupDb, - getPayto + getPayto, } from "../harness/harness.js"; /** diff --git a/packages/taler-harness/src/integrationtests/test-merchant-longpolling.ts b/packages/taler-harness/src/integrationtests/test-merchant-longpolling.ts index 4b9f53f05..7d2ba99b2 100644 --- a/packages/taler-harness/src/integrationtests/test-merchant-longpolling.ts +++ b/packages/taler-harness/src/integrationtests/test-merchant-longpolling.ts @@ -18,7 +18,10 @@ * Imports. */ import { GlobalTestState, MerchantPrivateApi } from "../harness/harness.js"; -import { createSimpleTestkudosEnvironment, withdrawViaBank } from "../harness/helpers.js"; +import { + createSimpleTestkudosEnvironment, + withdrawViaBank, +} from "../harness/helpers.js"; import { PreparePayResultType, codecForMerchantOrderStatusUnpaid, @@ -35,12 +38,8 @@ import { WalletApiOperation } from "@gnu-taler/taler-wallet-core"; export async function runMerchantLongpollingTest(t: GlobalTestState) { // Set up test environment - const { - wallet, - bank, - exchange, - merchant, - } = await createSimpleTestkudosEnvironment(t); + const { wallet, bank, exchange, merchant } = + await createSimpleTestkudosEnvironment(t); // Withdraw digital cash into the wallet. diff --git a/packages/taler-harness/src/integrationtests/test-payment-abort.ts b/packages/taler-harness/src/integrationtests/test-payment-abort.ts index 40175cec9..a165c1e09 100644 --- a/packages/taler-harness/src/integrationtests/test-payment-abort.ts +++ b/packages/taler-harness/src/integrationtests/test-payment-abort.ts @@ -22,7 +22,10 @@ import { withdrawViaBank, createFaultInjectedMerchantTestkudosEnvironment, } from "../harness/helpers.js"; -import { FaultInjectionRequestContext, FaultInjectionResponseContext } from "../harness/faultInjection.js"; +import { + FaultInjectionRequestContext, + FaultInjectionResponseContext, +} from "../harness/faultInjection.js"; import { codecForMerchantOrderStatusUnpaid, ConfirmPayResultType, @@ -147,7 +150,10 @@ export async function runPaymentAbortTest(t: GlobalTestState) { await wallet.runUntilDone(); - const txns2 = await wallet.client.call(WalletApiOperation.GetTransactions, {}); + const txns2 = await wallet.client.call( + WalletApiOperation.GetTransactions, + {}, + ); console.log(j2s(txns2)); const txTypes = txns2.transactions.map((x) => x.type); diff --git a/packages/taler-harness/src/integrationtests/test-payment-forgettable.ts b/packages/taler-harness/src/integrationtests/test-payment-forgettable.ts index 3bdd6bef3..b66eda2f1 100644 --- a/packages/taler-harness/src/integrationtests/test-payment-forgettable.ts +++ b/packages/taler-harness/src/integrationtests/test-payment-forgettable.ts @@ -30,12 +30,8 @@ import { export async function runPaymentForgettableTest(t: GlobalTestState) { // Set up test environment - const { - wallet, - bank, - exchange, - merchant, - } = await createSimpleTestkudosEnvironment(t); + const { wallet, bank, exchange, merchant } = + await createSimpleTestkudosEnvironment(t); // Withdraw digital cash into the wallet. diff --git a/packages/taler-harness/src/integrationtests/test-payment-multiple.ts b/packages/taler-harness/src/integrationtests/test-payment-multiple.ts index 46325c05f..25e19ae8e 100644 --- a/packages/taler-harness/src/integrationtests/test-payment-multiple.ts +++ b/packages/taler-harness/src/integrationtests/test-payment-multiple.ts @@ -25,15 +25,13 @@ import { MerchantService, WalletCli, MerchantPrivateApi, - getPayto + getPayto, } from "../harness/harness.js"; import { withdrawViaBank } from "../harness/helpers.js"; import { coin_ct10, coin_u1 } from "../harness/denomStructures.js"; import { WalletApiOperation } from "@gnu-taler/taler-wallet-core"; -async function setupTest( - t: GlobalTestState, -): Promise<{ +async function setupTest(t: GlobalTestState): Promise<{ merchant: MerchantService; exchange: ExchangeService; bank: BankService; diff --git a/packages/taler-harness/src/integrationtests/test-payment-transient.ts b/packages/taler-harness/src/integrationtests/test-payment-transient.ts index b57b355c6..a837a1b33 100644 --- a/packages/taler-harness/src/integrationtests/test-payment-transient.ts +++ b/packages/taler-harness/src/integrationtests/test-payment-transient.ts @@ -22,9 +22,7 @@ import { withdrawViaBank, createFaultInjectedMerchantTestkudosEnvironment, } from "../harness/helpers.js"; -import { - FaultInjectionResponseContext, -} from "../harness/faultInjection.js"; +import { FaultInjectionResponseContext } from "../harness/faultInjection.js"; import { codecForMerchantOrderStatusUnpaid, ConfirmPayResultType, @@ -44,12 +42,8 @@ const axios = axiosImp.default; export async function runPaymentTransientTest(t: GlobalTestState) { // Set up test environment - const { - wallet, - bank, - exchange, - faultyMerchant, - } = await createFaultInjectedMerchantTestkudosEnvironment(t); + const { wallet, bank, exchange, faultyMerchant } = + await createFaultInjectedMerchantTestkudosEnvironment(t); // Withdraw digital cash into the wallet. @@ -81,8 +75,6 @@ export async function runPaymentTransientTest(t: GlobalTestState) { }); if (publicOrderStatusResp.status != 402) { - - throw Error( `expected status 402 (before claiming), but got ${publicOrderStatusResp.status}`, ); diff --git a/packages/taler-harness/src/integrationtests/test-payment-zero.ts b/packages/taler-harness/src/integrationtests/test-payment-zero.ts index c38b8b382..6c28da30c 100644 --- a/packages/taler-harness/src/integrationtests/test-payment-zero.ts +++ b/packages/taler-harness/src/integrationtests/test-payment-zero.ts @@ -32,12 +32,8 @@ import { export async function runPaymentZeroTest(t: GlobalTestState) { // Set up test environment - const { - wallet, - bank, - exchange, - merchant, - } = await createSimpleTestkudosEnvironment(t); + const { wallet, bank, exchange, merchant } = + await createSimpleTestkudosEnvironment(t); // First, make a "free" payment when we don't even have // any money in the diff --git a/packages/taler-harness/src/integrationtests/test-payment.ts b/packages/taler-harness/src/integrationtests/test-payment.ts index b4c1f0cae..60d8e320d 100644 --- a/packages/taler-harness/src/integrationtests/test-payment.ts +++ b/packages/taler-harness/src/integrationtests/test-payment.ts @@ -30,12 +30,8 @@ import { export async function runPaymentTest(t: GlobalTestState) { // Set up test environment - const { - wallet, - bank, - exchange, - merchant, - } = await createSimpleTestkudosEnvironment(t); + const { wallet, bank, exchange, merchant } = + await createSimpleTestkudosEnvironment(t); // Withdraw digital cash into the wallet. diff --git a/packages/taler-harness/src/integrationtests/test-peer-to-peer-pull.ts b/packages/taler-harness/src/integrationtests/test-peer-to-peer-pull.ts index af4d4d1d9..80978e726 100644 --- a/packages/taler-harness/src/integrationtests/test-peer-to-peer-pull.ts +++ b/packages/taler-harness/src/integrationtests/test-peer-to-peer-pull.ts @@ -61,7 +61,7 @@ export async function runPeerToPeerPullTest(t: GlobalTestState) { partialContractTerms: { summary: "Hello World", amount: "TESTKUDOS:5", - purse_expiration + purse_expiration, }, }, ); diff --git a/packages/taler-harness/src/integrationtests/test-peer-to-peer-push.ts b/packages/taler-harness/src/integrationtests/test-peer-to-peer-push.ts index eb29a81c2..39d9b9edb 100644 --- a/packages/taler-harness/src/integrationtests/test-peer-to-peer-push.ts +++ b/packages/taler-harness/src/integrationtests/test-peer-to-peer-push.ts @@ -61,7 +61,7 @@ export async function runPeerToPeerPushTest(t: GlobalTestState) { partialContractTerms: { summary: "Hello World 😁😇", amount: "TESTKUDOS:5", - purse_expiration + purse_expiration, }, }, ); @@ -74,7 +74,7 @@ export async function runPeerToPeerPushTest(t: GlobalTestState) { partialContractTerms: { summary: "Hello World 🥺", amount: "TESTKUDOS:5", - purse_expiration + purse_expiration, }, }, ); @@ -115,16 +115,13 @@ export async function runPeerToPeerPushTest(t: GlobalTestState) { console.log(`txn2: ${j2s(txn2)}`); const ex1 = await t.assertThrowsTalerErrorAsync(async () => { - await wallet1.client.call( - WalletApiOperation.InitiatePeerPushPayment, - { - partialContractTerms: { - summary: "(this will fail)", - amount: "TESTKUDOS:15", - purse_expiration - }, + await wallet1.client.call(WalletApiOperation.InitiatePeerPushPayment, { + partialContractTerms: { + summary: "(this will fail)", + amount: "TESTKUDOS:15", + purse_expiration, }, - ); + }); }); console.log("got expected exception detail", j2s(ex1.errorDetail)); diff --git a/packages/taler-harness/src/integrationtests/test-refund.ts b/packages/taler-harness/src/integrationtests/test-refund.ts index 91dee4905..93850769a 100644 --- a/packages/taler-harness/src/integrationtests/test-refund.ts +++ b/packages/taler-harness/src/integrationtests/test-refund.ts @@ -103,9 +103,12 @@ export async function runRefundTest(t: GlobalTestState) { } { - const r3 = await wallet.client.call(WalletApiOperation.ApplyRefundFromPurchaseId, { - purchaseId: r1.proposalId - }); + const r3 = await wallet.client.call( + WalletApiOperation.ApplyRefundFromPurchaseId, + { + purchaseId: r1.proposalId, + }, + ); console.log(r3); await wallet.runUntilDone(); diff --git a/packages/taler-harness/src/integrationtests/test-timetravel-autorefresh.ts b/packages/taler-harness/src/integrationtests/test-timetravel-autorefresh.ts index 54b66e0b2..50f9cbcd3 100644 --- a/packages/taler-harness/src/integrationtests/test-timetravel-autorefresh.ts +++ b/packages/taler-harness/src/integrationtests/test-timetravel-autorefresh.ts @@ -36,7 +36,7 @@ import { MerchantService, setupDb, WalletCli, - getPayto + getPayto, } from "../harness/harness.js"; import { startWithdrawViaBank, withdrawViaBank } from "../harness/helpers.js"; diff --git a/packages/taler-harness/src/integrationtests/test-wallet-balance.ts b/packages/taler-harness/src/integrationtests/test-wallet-balance.ts index 0214dc5ce..b5b1917a6 100644 --- a/packages/taler-harness/src/integrationtests/test-wallet-balance.ts +++ b/packages/taler-harness/src/integrationtests/test-wallet-balance.ts @@ -143,7 +143,9 @@ export async function runWalletBalanceTest(t: GlobalTestState) { ); t.assertTrue( - Amounts.isNonZero(preparePayResult.balanceDetails.balanceMerchantAcceptable), + Amounts.isNonZero( + preparePayResult.balanceDetails.balanceMerchantAcceptable, + ), ); t.assertTrue( diff --git a/packages/taler-harness/src/integrationtests/test-wallet-dbless.ts b/packages/taler-harness/src/integrationtests/test-wallet-dbless.ts index 269a8b240..7692f12b2 100644 --- a/packages/taler-harness/src/integrationtests/test-wallet-dbless.ts +++ b/packages/taler-harness/src/integrationtests/test-wallet-dbless.ts @@ -43,7 +43,9 @@ export async function runWalletDblessTest(t: GlobalTestState) { const { bank, exchange } = await createSimpleTestkudosEnvironment(t); const http = new NodeHttpLib(); - const cryptiDisp = new CryptoDispatcher(new SynchronousCryptoWorkerFactoryNode()); + const cryptiDisp = new CryptoDispatcher( + new SynchronousCryptoWorkerFactoryNode(), + ); const cryptoApi = cryptiDisp.cryptoApi; try { -- cgit v1.2.3