Merge branch 'develop' into upstream/2025.5.0
This commit is contained in:
commit
33aee38a59
125 changed files with 3926 additions and 2148 deletions
|
|
@ -4,6 +4,8 @@
|
|||
*/
|
||||
|
||||
import { Test, TestingModule } from '@nestjs/testing';
|
||||
import { FakeInternalEventService } from '../../misc/FakeInternalEventService.js';
|
||||
import { NoOpCacheService } from '../../misc/noOpCaches.js';
|
||||
import type { MiUser } from '@/models/User.js';
|
||||
import { UserEntityService } from '@/core/entities/UserEntityService.js';
|
||||
import { GlobalModule } from '@/GlobalModule.js';
|
||||
|
|
@ -51,6 +53,7 @@ import { ReactionService } from '@/core/ReactionService.js';
|
|||
import { NotificationService } from '@/core/NotificationService.js';
|
||||
import { ReactionsBufferingService } from '@/core/ReactionsBufferingService.js';
|
||||
import { ChatService } from '@/core/ChatService.js';
|
||||
import { InternalEventService } from '@/core/InternalEventService.js';
|
||||
|
||||
process.env.NODE_ENV = 'test';
|
||||
|
||||
|
|
@ -174,6 +177,7 @@ describe('UserEntityService', () => {
|
|||
ReactionsBufferingService,
|
||||
NotificationService,
|
||||
ChatService,
|
||||
InternalEventService,
|
||||
];
|
||||
|
||||
app = await Test.createTestingModule({
|
||||
|
|
@ -182,7 +186,10 @@ describe('UserEntityService', () => {
|
|||
...services,
|
||||
...services.map(x => ({ provide: x.name, useExisting: x })),
|
||||
],
|
||||
}).compile();
|
||||
})
|
||||
.overrideProvider(InternalEventService).useClass(FakeInternalEventService)
|
||||
.overrideProvider(CacheService).useClass(NoOpCacheService)
|
||||
.compile();
|
||||
await app.init();
|
||||
app.enableShutdownHooks();
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue