This commit is contained in:
Ben Irvin 2023-08-10 15:40:01 +02:00
parent 995473d959
commit fc2ee1dd16
2 changed files with 4 additions and 7 deletions

View File

@ -89,7 +89,7 @@ const pagination = {
pageCount: 1,
};
describe('Sanitization - Filter private params', () => {
describe('Validation - private params', () => {
const builder = createTestBuilder();
beforeAll(async () => {
@ -109,7 +109,8 @@ describe('Sanitization - Filter private params', () => {
)
);
});
test('Filter by createdBy user email', async () => {
test('Error when filters has createdBy user email', async () => {
const res = await rq({
method: 'GET',
url: '/collectors',
@ -124,10 +125,6 @@ describe('Sanitization - Filter private params', () => {
},
});
// The filter should be completely ignored, so we should get all the collectors
expect(res.body.meta.pagination).toMatchObject({
...pagination,
total: 3,
});
expect(res.statusCode).toBe(400);
});
});