mirror of
https://github.com/Unleash/unleash.git
synced 2025-06-09 01:17:06 +02:00
chore: reduce test time-complexity
This commit is contained in:
parent
73685c771a
commit
b1a2f110c6
@ -54,7 +54,7 @@ test('returns empty list of users', async () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
test('creates and returns all users', async () => {
|
test('creates and returns all users', async () => {
|
||||||
const createUserRequests = [...Array(20).keys()].map((i) =>
|
const createUserRequests = [...Array(10).keys()].map((i) =>
|
||||||
app.request
|
app.request
|
||||||
.post('/api/admin/user-admin')
|
.post('/api/admin/user-admin')
|
||||||
.send({
|
.send({
|
||||||
@ -72,7 +72,7 @@ test('creates and returns all users', async () => {
|
|||||||
.expect('Content-Type', /json/)
|
.expect('Content-Type', /json/)
|
||||||
.expect(200)
|
.expect(200)
|
||||||
.expect((res) => {
|
.expect((res) => {
|
||||||
expect(res.body.users.length).toBe(20);
|
expect(res.body.users.length).toBe(10);
|
||||||
expect(res.body.users[2].rootRole).toBe(editorRole.id);
|
expect(res.body.users[2].rootRole).toBe(editorRole.id);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user