mirror of
https://github.com/KevinMidboe/immich.git
synced 2026-01-10 03:05:50 +00:00
- Refactor user business logic from `user.service` into `user.domain` Make user business logic reusable by using `user.domain` from other services than `user.service` - Add `jest-when` lib to make testing easier and use it in `userService` Using when helps from coupling tests to order of mock implementations execution - Move all user business logic from user-repository to user.service - Fix user.service tests not awaiting promises leaking state between tests - Presentation logic for `getUserProfileImage` moved from UserService to UserController - Fix `user.e2e` test logic. Pending fixing the configuration of the test itself
22 lines
905 B
JSON
22 lines
905 B
JSON
{
|
|
"moduleFileExtensions": ["js", "json", "ts"],
|
|
"rootDir": ".",
|
|
"testEnvironment": "node",
|
|
"testRegex": ".e2e-spec.ts$",
|
|
"transform": {
|
|
"^.+\\.(t|j)s$": "ts-jest"
|
|
},
|
|
"moduleNameMapper": {
|
|
"^@app/database(|/.*)$": "<rootDir>../../../libs/database/src/$1",
|
|
"@app/database/config": "<rootDir>../../../libs/database/src/config",
|
|
"@app/database/config/(.*)": "<rootDir>../../../libs/database/src/config/$1",
|
|
"@app/database/entities/(.*)": "<rootDir>../../../libs/database/src/entities/$1",
|
|
"@app/common": "<rootDir>../../../libs/common/src",
|
|
"@app/common/(.*)": "<rootDir>../../../libs/common/src/$1",
|
|
"^@app/job(|/.*)$": "<rootDir>../../../libs/job/src/$1",
|
|
"@app/job": "<rootDir>../../../libs/job/src",
|
|
"^@app/immich-config(|/.*)$": "<rootDir>../../../libs/immich-config/src/$1",
|
|
"^@app/storage(|/.*)$": "<rootDir>../../../libs/storage/src/$1"
|
|
}
|
|
}
|