Fix jwt-token

This commit is contained in:
2025-09-16 07:17:31 +02:00
parent 104243810d
commit c9a38acfbb
2 changed files with 7 additions and 0 deletions

View File

@@ -32,6 +32,8 @@ let models;
* Setup test environment before all tests
*/
async function setupTestEnvironment() {
console.log('🔧 DEBUG: setupTestEnvironment() called - global.__TEST_MODELS__ before:', !!global.__TEST_MODELS__);
// Clear any existing global models
delete global.__TEST_MODELS__;
@@ -93,6 +95,7 @@ async function setupTestEnvironment() {
// Store models globally for routes to access
global.__TEST_MODELS__ = models;
console.log('🔧 DEBUG: Global models set at end of setupTestEnvironment:', Object.keys(global.__TEST_MODELS__));
// Debug info
console.log(`🔧 DEBUG: Test sequelize instance: ${sequelize.constructor.name}`);