mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2024-11-25 11:16:31 -05:00
Note E2E tests: Use on-disk sqlite to aid debugging
It was helpful to inspect database contents while the code was stopped by the debugger. Therefore the E2E test database is now persisted on disk and cleared before every test-run. Signed-off-by: David Mehren <git@herrmehren.de>
This commit is contained in:
parent
cf88cde551
commit
2030141c66
1 changed files with 3 additions and 1 deletions
|
@ -21,7 +21,7 @@ describe('Notes', () => {
|
|||
GroupsModule,
|
||||
TypeOrmModule.forRoot({
|
||||
type: 'sqlite',
|
||||
database: ':memory:',
|
||||
database: './hedgedoc-e2e.sqlite',
|
||||
autoLoadEntities: true,
|
||||
synchronize: true,
|
||||
}),
|
||||
|
@ -31,6 +31,8 @@ describe('Notes', () => {
|
|||
app = moduleRef.createNestApplication();
|
||||
await app.init();
|
||||
notesService = moduleRef.get(NotesService);
|
||||
const noteRepository = moduleRef.get('NoteRepository');
|
||||
noteRepository.clear();
|
||||
});
|
||||
|
||||
it(`POST /notes`, async () => {
|
||||
|
|
Loading…
Reference in a new issue