Refactor database configuration and enhance error handling in authentication services
Updated the database configuration to centralize settings and improve maintainability. Enhanced error handling in the authentication service to provide clearer and more specific error messages for various failure scenarios, including registration, activation, and login processes. Additionally, added new dependencies for testing and SQLite support in the package.json file.
This commit is contained in:
14
backend/vitest.config.js
Normal file
14
backend/vitest.config.js
Normal file
@@ -0,0 +1,14 @@
|
||||
import { defineConfig } from 'vitest/config';
|
||||
|
||||
export default defineConfig({
|
||||
test: {
|
||||
globals: true,
|
||||
environment: 'node',
|
||||
setupFiles: ['./tests/setupTestEnv.js'],
|
||||
include: ['tests/**/*.test.js'],
|
||||
coverage: {
|
||||
reporter: ['text', 'html'],
|
||||
exclude: ['migrations/**', 'uploads/**', 'scripts/**'],
|
||||
},
|
||||
},
|
||||
});
|
||||
Reference in New Issue
Block a user