-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Pyic 7785: Add API tests to complete a strategic app journey (#2870)
- Loading branch information
Showing
15 changed files
with
360 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import { After } from "@cucumber/cucumber"; | ||
|
||
After({ tags: "@InitialisesDCMAWSessionState" }, async function () { | ||
const response = await fetch( | ||
`https://dcmaw-async.stubs.account.gov.uk/management/cleanupDcmawState`, | ||
{ | ||
method: "POST", | ||
body: JSON.stringify({ | ||
user_id: this.userId, | ||
}), | ||
redirect: "manual", | ||
}, | ||
); | ||
|
||
if (response.status !== 200) { | ||
throw new Error( | ||
`DCMAW session state cleanup request failed: ${response.statusText}`, | ||
); | ||
} | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.