taler-typescript-core

Wallet core logic and WebUIs for various components
Log | Files | Refs | Submodules | README | LICENSE

commit 702b552cb63f09053c8353d71bde69436437096d
parent d3038348a79d2598b0318851e8dde91a083a8c9b
Author: Florian Dold <florian@dold.me>
Date:   Thu, 12 Mar 2026 13:00:47 +0100

harness: work around typst path issues

Diffstat:
Mpackages/taler-harness/src/integrationtests/test-merchant-reports.ts | 11++++++++++-
Mpackages/taler-harness/src/integrationtests/test-tops-aml-pdf.ts | 9+++++++--
2 files changed, 17 insertions(+), 3 deletions(-)

diff --git a/packages/taler-harness/src/integrationtests/test-merchant-reports.ts b/packages/taler-harness/src/integrationtests/test-merchant-reports.ts @@ -32,11 +32,20 @@ import { useSharedTestkudosEnvironment, withdrawViaBankV3, } from "../harness/environments.js"; -import { GlobalTestState } from "../harness/harness.js"; +import { GlobalTestState, sh } from "../harness/harness.js"; export async function runMerchantReportsTest(t: GlobalTestState) { // Set up test environment + // Hack to work around odd install location of typst templates. + // See https://bugs.gnunet.org/view.php?id=11241 + const prefix = ( + await sh(t, "merchant-config", "taler-merchant-config -s paths -o prefix") + ).trim(); + process.env["XDG_DATA_HOME"] = `${prefix}/.local/share/`; + + console.log(`XDG_DATA_HOME: ${process.env["XDG_DATA_HOME"]}`); + const { walletClient, bank, exchange, merchant, merchantAdminAccessToken } = await useSharedTestkudosEnvironment(t); diff --git a/packages/taler-harness/src/integrationtests/test-tops-aml-pdf.ts b/packages/taler-harness/src/integrationtests/test-tops-aml-pdf.ts @@ -19,7 +19,7 @@ */ import { Logger, succeedOrThrow } from "@gnu-taler/taler-util"; import * as fs from "node:fs"; -import { GlobalTestState } from "../harness/harness.js"; +import { GlobalTestState, sh } from "../harness/harness.js"; import { setupMeasuresTestEnvironment } from "../harness/tops.js"; export const logger = new Logger("test-tops-aml-measures.ts"); @@ -86,7 +86,12 @@ ${330 + contentStream.length} * Test that invokes all measures defined for the TOPS deployment. */ export async function runTopsAmlPdfTest(t: GlobalTestState) { - // Setup is done, now the real testing can start! + // Hack to work around odd install location of typst templates. + // See https://bugs.gnunet.org/view.php?id=11241 + const prefix = ( + await sh(t, "merchant-config", "taler-exchange-config -s paths -o prefix") + ).trim(); + process.env["XDG_DATA_HOME"] = `${prefix}/.local/share/`; const { decideMeasure,