Skip to content

Commit 049d591

Browse files
committed
fix(server): restructure Jest tests and standardize test scripts
1 parent d8da27c commit 049d591

6 files changed

Lines changed: 128 additions & 255 deletions

File tree

packages/server/package.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,9 @@
4747
"cypress:run": "cypress run",
4848
"e2e": "start-server-and-test dev http://localhost:3000 cypress:run",
4949
"cypress:ci": "START_SERVER_AND_TEST_INSECURE=1 start-server-and-test start https-get://localhost:3000 cypress:run",
50-
"test": "jest --runInBand --detectOpenHandles --forceExit"
50+
"test": "jest",
51+
"test:watch": "jest --watch",
52+
"test:coverage": "jest --coverage"
5153
},
5254
"keywords": [],
5355
"homepage": "https://flowiseai.com",

packages/server/test/index.test.ts

Lines changed: 0 additions & 30 deletions
This file was deleted.

packages/server/test/routes/v1/organization-user.route.test.ts

Lines changed: 0 additions & 39 deletions
This file was deleted.

packages/server/test/routes/v1/user.route.test.ts

Lines changed: 0 additions & 54 deletions
This file was deleted.
Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
import { generateAPIKey } from '../../src/utils/apiKey'
22

3-
export function apiKeyTest() {
4-
describe('Api Key', () => {
5-
it('should be able to generate a new api key', () => {
6-
const apiKey = generateAPIKey()
7-
expect(typeof apiKey === 'string').toEqual(true)
8-
})
3+
describe('Api Key', () => {
4+
it('should be able to generate a new api key', () => {
5+
const apiKey = generateAPIKey()
6+
expect(typeof apiKey === 'string').toEqual(true)
97
})
10-
}
8+
})

0 commit comments

Comments
 (0)