From 50c3f9ce87337f435b35d67e752862077af23de9 Mon Sep 17 00:00:00 2001 From: babblebey Date: Thu, 29 Aug 2024 17:58:50 +0100 Subject: [PATCH] test: `Verify, release and notify success` fix attempt --- test/integration.test.js | 32 ++++++++++++-------------------- 1 file changed, 12 insertions(+), 20 deletions(-) diff --git a/test/integration.test.js b/test/integration.test.js index c5a38dc4..d39ffd37 100644 --- a/test/integration.test.js +++ b/test/integration.test.js @@ -682,29 +682,22 @@ test("Verify, release and notify success", async (t) => { repeat: 2, }, ) - .postOnce( - (url, { body }) => { - t.is(url, "https://api.github.local/graphql"); - t.regex(JSON.parse(body).query, /query getAssociatedPRs\(/); - return true; - }, - { - data: { - repository: { - commit123: { - oid: "123", - associatedPullRequests: { - pageInfo: { - endCursor: "NI", - hasNextPage: false, - }, - nodes: [prs[0]], + .postOnce("https://api.github.local/graphql", { + data: { + repository: { + commit123: { + oid: "123", + associatedPullRequests: { + pageInfo: { + endCursor: "NI", + hasNextPage: false, }, + nodes: [prs[0]], }, }, }, }, - ) + }) .postOnce( `https://api.github.local/repos/${owner}/${repo}/releases`, { @@ -737,8 +730,7 @@ test("Verify, release and notify success", async (t) => { { body: ["released"] }, ) .postOnce( - (url, { body }) => { - t.is(url, "https://api.github.local/graphql"); + (_, { body }) => { t.regex(JSON.parse(body).query, /query getSRIssues\(/); return true; },