Skip to content

Commit

Permalink
fix test cases
Browse files Browse the repository at this point in the history
  • Loading branch information
imagekitio authored Nov 8, 2023
1 parent 62a4eed commit d0e1cd3
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/mediaLibrary.js
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,7 @@ describe("Media library APIs", function () {

it('Rename file - default purgeCache value', function (done) {
const scope = nock('https://api.imagekit.io')
.post(`/v1/files/rename`)
.put(`/v1/files/rename`)
.basicAuth({ user: initializationParams.privateKey, pass: '' })
.reply(function (uri, requestBody) {
expect(this.req.path).equal(`/v1/files/rename`)
Expand All @@ -330,7 +330,7 @@ describe("Media library APIs", function () {

it('Rename file', function (done) {
const scope = nock('https://api.imagekit.io')
.post(`/v1/files/rename`)
.put(`/v1/files/rename`)
.basicAuth({ user: initializationParams.privateKey, pass: '' })
.reply(function (uri, requestBody) {
expect(this.req.path).equal(`/v1/files/rename`)
Expand Down Expand Up @@ -1141,7 +1141,7 @@ describe("Media library APIs", function () {

it('Rename file', function (done) {
const scope = nock('https://api.imagekit.io')
.post(`/v1/files/rename`)
.put(`/v1/files/rename`)
.basicAuth({ user: initializationParams.privateKey, pass: '' })
.reply(204, dummyAPISuccessResponse)

Expand Down Expand Up @@ -1508,7 +1508,7 @@ describe("Media library APIs", function () {

it('Rename file', function (done) {
const scope = nock('https://api.imagekit.io')
.post(`/v1/files/rename`)
.put(`/v1/files/rename`)
.basicAuth({ user: initializationParams.privateKey, pass: '' })
.reply(500, dummyAPIErrorResponse)

Expand Down

0 comments on commit d0e1cd3

Please sign in to comment.