knee-cola / jest-mock-axios

Axios mock for Jest
252 stars 42 forks source link

MockAxios.defaults is different on github from published npm package #92

Closed CezarManea closed 1 year ago

CezarManea commented 1 year ago

In version 4.7.0-beta3 the MockAxios.defaults is different from github code. https://www.npmjs.com/package/jest-mock-axios/v/4.7.0-beta3?activeTab=explore

MockAxios.defaults = {
  headers: {
    common: []
  }
};

vs https://github.com/knee-cola/jest-mock-axios/blob/v4.7.0-beta3/lib/mock-axios.ts#L137

MockAxios.defaults = {
    headers: {
        common: [],
        get: {},
        post: {},
        delete: {},
        put: {},
        patch: {},
        head: {}
    },
};

Maybe something is broken in the publishing pipeline? @kingjan1999

kingjan1999 commented 1 year ago

Should be fixed with 4.7.0-beta4, sorry for the inconvenience