diff --git a/__tests__/cmds/docs.test.js b/__tests__/cmds/docs.test.js index 594ced066..003f15368 100644 --- a/__tests__/cmds/docs.test.js +++ b/__tests__/cmds/docs.test.js @@ -71,10 +71,10 @@ describe('rdme docs', () => { expect.assertions(1); const getMocks = getNockWithVersionHeader(version) - .get(`/api/v1/docs/simple-doc`) + .get('/api/v1/docs/simple-doc') .basicAuth({ user: key }) .reply(200, { category, slug: simpleDoc.slug, lastUpdatedHash: 'anOldHash' }) - .get(`/api/v1/docs/another-doc`) + .get('/api/v1/docs/another-doc') .basicAuth({ user: key }) .reply(200, { category, slug: anotherDoc.slug, lastUpdatedHash: 'anOldHash' }); @@ -170,7 +170,7 @@ describe('rdme docs', () => { }); const postMock = getNockWithVersionHeader(version) - .post(`/api/v1/docs`, { slug, body: doc.content, ...doc.data, lastUpdatedHash: hash }) + .post('/api/v1/docs', { slug, body: doc.content, ...doc.data, lastUpdatedHash: hash }) .basicAuth({ user: key }) .reply(201, { slug, body: doc.content, ...doc.data, lastUpdatedHash: hash }); @@ -295,7 +295,7 @@ describe('rdme docs', () => { }); const postMock = getNockWithVersionHeader(version) - .post(`/api/v1/docs`, { slug, body: doc.content, ...doc.data, lastUpdatedHash: hash }) + .post('/api/v1/docs', { slug, body: doc.content, ...doc.data, lastUpdatedHash: hash }) .basicAuth({ user: key }) .reply(201, { slug: doc.data.slug, body: doc.content, ...doc.data, lastUpdatedHash: hash }); diff --git a/__tests__/cmds/openapi.test.js b/__tests__/cmds/openapi.test.js index e394a2854..b8dcc8393 100644 --- a/__tests__/cmds/openapi.test.js +++ b/__tests__/cmds/openapi.test.js @@ -35,13 +35,13 @@ describe('rdme openapi', () => { promptHandler.createOasPrompt.mockResolvedValue({ option: 'create' }); const mock = nock(config.host) - .get(`/api/v1/version`) + .get('/api/v1/version') .basicAuth({ user: key }) .reply(200, [{ version }]) .post('/api/v1/version') .basicAuth({ user: key }) .reply(200, { from: '1.0.1', version: '1.0.1' }) - .get(`/api/v1/api-specification`) + .get('/api/v1/api-specification') .basicAuth({ user: key }) .reply(200, []) .post('/api/v1/api-specification', body => body.match('form-data; name="spec"')) @@ -73,7 +73,7 @@ describe('rdme openapi', () => { .get(`/api/v1/version/${version}`) .basicAuth({ user: key }) .reply(200, { version: '1.0.0' }) - .get(`/api/v1/api-specification`) + .get('/api/v1/api-specification') .basicAuth({ user: key }) .reply(200, []) .post('/api/v1/api-specification', body => body.match('form-data; name="spec"')) @@ -99,7 +99,7 @@ describe('rdme openapi', () => { it('should POST to the swagger api if no id provided', () => { const mock = nock(config.host) - .get(`/api/v1/api-specification`) + .get('/api/v1/api-specification') .basicAuth({ user: key }) .reply(200, []) .get(`/api/v1/version/${version}`) @@ -127,7 +127,7 @@ describe('rdme openapi', () => { .get(`/api/v1/version/${version}`) .basicAuth({ user: key }) .reply(200, { version: '1.0.0' }) - .get(`/api/v1/api-specification`) + .get('/api/v1/api-specification') .basicAuth({ user: key }) .reply(200, []) .post('/api/v1/api-specification', body => body.match('form-data; name="spec"')) @@ -165,7 +165,7 @@ describe('rdme openapi', () => { .post('/api/v1/version') .basicAuth({ user: key }) .reply(200, { from: '1.0.1', version: '1.0.1' }) - .get(`/api/v1/api-specification`) + .get('/api/v1/api-specification') .basicAuth({ user: key }) .reply(200, []) .post('/api/v1/api-specification', body => body.match('form-data; name="spec"')) @@ -213,7 +213,7 @@ describe('rdme openapi', () => { it('should bundle and upload the expected content', () => { let requestBody = null; const mock = nock(config.host) - .get(`/api/v1/api-specification`) + .get('/api/v1/api-specification') .basicAuth({ user: key }) .reply(200, []) .get(`/api/v1/version/${version}`) diff --git a/__tests__/cmds/versions.test.js b/__tests__/cmds/versions.test.js index b6173b0d0..8bef257ba 100644 --- a/__tests__/cmds/versions.test.js +++ b/__tests__/cmds/versions.test.js @@ -113,7 +113,7 @@ describe('rdme versions*', () => { .get('/api/v1/version') .basicAuth({ user: key }) .reply(200, [{ version }, { version }]) - .post(`/api/v1/version`) + .post('/api/v1/version') .basicAuth({ user: key }) .reply(201, { version });