mirror of
https://github.com/strapi/strapi.git
synced 2025-11-13 08:38:09 +00:00
fix typos
This commit is contained in:
parent
a4e0df4ce8
commit
f791c21cc9
@ -177,7 +177,7 @@ describe('API Token Controller', () => {
|
|||||||
expect(send).toHaveBeenCalledWith({ data: token });
|
expect(send).toHaveBeenCalledWith({ data: token });
|
||||||
});
|
});
|
||||||
|
|
||||||
test('Fails if the API token does not exists', async () => {
|
test('Fails if the API token does not exist', async () => {
|
||||||
const get = jest.fn().mockResolvedValue(null);
|
const get = jest.fn().mockResolvedValue(null);
|
||||||
const notFound = jest.fn();
|
const notFound = jest.fn();
|
||||||
const ctx = createContext({ params: { id: token.id } }, { notFound });
|
const ctx = createContext({ params: { id: token.id } }, { notFound });
|
||||||
|
|||||||
@ -225,7 +225,7 @@ describe('API Token', () => {
|
|||||||
expect(res).toEqual(token);
|
expect(res).toEqual(token);
|
||||||
});
|
});
|
||||||
|
|
||||||
test('It returns `null` if the resource does not exists', async () => {
|
test('It returns `null` if the resource does not exist', async () => {
|
||||||
const findOne = jest.fn().mockResolvedValue(null);
|
const findOne = jest.fn().mockResolvedValue(null);
|
||||||
|
|
||||||
global.strapi = {
|
global.strapi = {
|
||||||
|
|||||||
@ -17,7 +17,7 @@ const { createAuthRequest } = require('../../../../../test/helpers/request');
|
|||||||
* 7. Deletes a token (successfully)
|
* 7. Deletes a token (successfully)
|
||||||
* 8. Does not return an error if the ressource does not exist
|
* 8. Does not return an error if the ressource does not exist
|
||||||
* 9. Retrieves a token (successfully)
|
* 9. Retrieves a token (successfully)
|
||||||
* 10. Returns a 404 if the ressource does not exists
|
* 10. Returns a 404 if the ressource does not exist
|
||||||
*/
|
*/
|
||||||
|
|
||||||
describe('Admin API Token CRUD (e2e)', () => {
|
describe('Admin API Token CRUD (e2e)', () => {
|
||||||
@ -220,7 +220,7 @@ describe('Admin API Token CRUD (e2e)', () => {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
test('10. Returns a 404 if the ressource does not exists', async () => {
|
test('10. Returns a 404 if the ressource does not exist', async () => {
|
||||||
const res = await rq({
|
const res = await rq({
|
||||||
url: '/admin/api-tokens/42',
|
url: '/admin/api-tokens/42',
|
||||||
method: 'GET',
|
method: 'GET',
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user