Skip to content

Commit 6c98513

Browse files
committed
test(next-drupal): fix bug in jsonRpc test util and rename utils files
1 parent 5ed427e commit 6c98513

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
export * from "./data"
2-
export * from "./fetch"
3-
export * from "./logger"
2+
export * from "./spyOnFetch"
3+
export * from "./mockLogger"

packages/next-drupal/tests/utils/rpc.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ class JsonRpc extends NextDrupalBase {
88
this.apiPrefix = "/jsonrpc"
99
}
1010

11-
async execute(body) {
12-
const endpoint = await jsonRpc.buildEndpoint()
11+
async execute(body: object) {
12+
const endpoint = await this.buildEndpoint()
1313

14-
const response = await jsonRpc.fetch(endpoint, {
14+
const response = await this.fetch(endpoint, {
1515
method: "POST",
1616
body: JSON.stringify(body),
1717
withAuth: true,

0 commit comments

Comments
 (0)