Skip to content

Commit

Permalink
Another testfix...
Browse files Browse the repository at this point in the history
  • Loading branch information
squidsoup committed Sep 10, 2019
1 parent 659fca3 commit 96c7dc3
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions ui/src/app/base/sagas/http.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,17 @@ describe("http sagas", () => {

describe("delete scripts", () => {
it("returns a SUCCESS action", () => {
const action = { type: "DELETE_SCRIPT", payload: { name: "script-1" } };
const action = {
type: "DELETE_SCRIPT",
payload: { id: 1, name: "script-1" }
};
return expectSaga(deleteScriptSaga, action)
.provide([
[matchers.call.fn(getCookie, "csrftoken"), "csrf-token"],
[matchers.call.fn(api.scripts.delete, "csrf-token", "script-1"), true]
])
.put({ type: "DELETE_SCRIPT_START" })
.put({ type: "DELETE_SCRIPT_SUCCESS" })
.put({ type: "DELETE_SCRIPT_SUCCESS", payload: 1 })
.run();
});

Expand Down

0 comments on commit 96c7dc3

Please sign in to comment.