mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-03-13 12:12:50 +00:00
NotesController: Add missing mock repositories for testing
Signed-off-by: David Mehren <git@herrmehren.de>
This commit is contained in:
parent
7f81a57634
commit
f007b8539c
1 changed files with 3 additions and 0 deletions
|
@ -2,6 +2,7 @@ import { Test, TestingModule } from '@nestjs/testing';
|
|||
import { getRepositoryToken } from '@nestjs/typeorm';
|
||||
import { Note } from '../../../notes/note.entity';
|
||||
import { NotesService } from '../../../notes/notes.service';
|
||||
import { Authorship } from '../../../revisions/authorship.entity';
|
||||
import { Revision } from '../../../revisions/revision.entity';
|
||||
import { RevisionsModule } from '../../../revisions/revisions.module';
|
||||
import { NotesController } from './notes.controller';
|
||||
|
@ -19,6 +20,8 @@ describe('Notes Controller', () => {
|
|||
.useValue({})
|
||||
.overrideProvider(getRepositoryToken(Revision))
|
||||
.useValue({})
|
||||
.overrideProvider(getRepositoryToken(Authorship))
|
||||
.useValue({})
|
||||
.compile();
|
||||
|
||||
controller = module.get<NotesController>(NotesController);
|
||||
|
|
Loading…
Reference in a new issue