1
0
Fork 0
mirror of synced 2024-06-02 02:25:17 +12:00

Fix revert test with 400 status

This commit is contained in:
Pedro Silva 2022-10-10 14:24:34 +01:00
parent 83f3a02d23
commit b59cd28b1d

View file

@ -129,7 +129,7 @@ describe("Internal API - /applications endpoints", () => {
})
// Skip this test because of the if line 44 in InternalAPIClient.ts
it.skip("POST - Revert Changes without changes", async () => {
it("POST - Revert Changes without changes", async () => {
const [response, app] = await config.applications.create(generateApp())
expect(response).toHaveStatusCode(200)
expect(app.appId).toBeDefined()
@ -138,10 +138,12 @@ describe("Internal API - /applications endpoints", () => {
const [revertResponse, revert] = await config.applications.revert(app.appId ? app.appId : "")
expect(revertResponse).toHaveStatusCode(400)
expect(revert).toEqual({
message: "There is no version to revert to",
message: "App has not yet been deployed",
status: 400
})
})
it("POST - Revert Changes", async () => {
const [response, app] = await config.applications.create(generateApp())
expect(response).toHaveStatusCode(200)