aboutsummaryrefslogtreecommitdiff
path: root/packages/taler-wallet-cli/src/integrationtests/test-merchant-instances-urls.ts
diff options
context:
space:
mode:
authorFlorian Dold <florian@dold.me>2021-04-08 16:03:04 +0200
committerFlorian Dold <florian@dold.me>2021-04-08 16:03:04 +0200
commitb2edad2dac37ae0b964f60ee912a01783b49e549 (patch)
tree16ac1361111e101638acb9558c4abb54bf17c251 /packages/taler-wallet-cli/src/integrationtests/test-merchant-instances-urls.ts
parent4fa88007f958796d7fe65d0fe4f6f45fcf953887 (diff)
improve error reporting in test case
Diffstat (limited to 'packages/taler-wallet-cli/src/integrationtests/test-merchant-instances-urls.ts')
-rw-r--r--packages/taler-wallet-cli/src/integrationtests/test-merchant-instances-urls.ts20
1 files changed, 4 insertions, 16 deletions
diff --git a/packages/taler-wallet-cli/src/integrationtests/test-merchant-instances-urls.ts b/packages/taler-wallet-cli/src/integrationtests/test-merchant-instances-urls.ts
index 2a933219b..1274f8dca 100644
--- a/packages/taler-wallet-cli/src/integrationtests/test-merchant-instances-urls.ts
+++ b/packages/taler-wallet-cli/src/integrationtests/test-merchant-instances-urls.ts
@@ -17,7 +17,6 @@
/**
* Imports.
*/
-import { URL } from "@gnu-taler/taler-wallet-core";
import axios from "axios";
import {
ExchangeService,
@@ -62,14 +61,6 @@ export async function runMerchantInstancesUrlsTest(t: GlobalTestState) {
},
);
- const clientForMyinst = new MerchantApiClient(
- merchant.makeInstanceBaseUrl("myinst"),
- {
- method: "token",
- token: "secret-token:i-am-myinst",
- },
- );
-
await clientForDefault.createInstance({
id: "default",
address: {},
@@ -111,12 +102,13 @@ export async function runMerchantInstancesUrlsTest(t: GlobalTestState) {
},
validateStatus: () => true,
});
- console.log("checking", url);
+ console.log(
+ `checking ${url}, expected ${expectedStatus}, got ${resp.status}`,
+ );
t.assertDeepEqual(resp.status, expectedStatus);
}
const tokDefault = "secret-token:i-am-default";
- const tokMyinst = "secret-token:i-am-myinst";
const defaultBaseUrl = merchant.makeInstanceBaseUrl();
@@ -135,11 +127,7 @@ export async function runMerchantInstancesUrlsTest(t: GlobalTestState) {
);
// Non-default instances don't allow instance management.
- await check(
- `${defaultBaseUrl}instances/foo/private/instances`,
- "foo",
- 404,
- );
+ await check(`${defaultBaseUrl}instances/foo/private/instances`, "foo", 404);
await check(
`${defaultBaseUrl}instances/myinst/private/instances`,
"foo",