feat(test): add jest test suite

This commit is contained in:
Vben
2021-06-17 22:56:21 +08:00
parent 154ebc3d96
commit f6fe1dd62d
33 changed files with 1898 additions and 209 deletions

23
tests/server/routes.ts Normal file
View File

@@ -0,0 +1,23 @@
import UserController from './controller/UserController';
import FileController from './controller/FileController';
export default [
// user
{
path: '/login',
method: 'post',
action: UserController.login,
},
{
path: '/getUserInfoById',
method: 'get',
action: UserController.getUserInfoById,
},
// file
{
path: '/upload',
method: 'post',
action: FileController.upload,
},
];