E2E Tests: Fix ESLint errors

Signed-off-by: David Mehren <git@herrmehren.de>
This commit is contained in:
David Mehren 2021-04-29 22:06:45 +02:00
parent 30712abe31
commit b518583fd2
No known key found for this signature in database
GPG key ID: 185982BA4C42B7C3
2 changed files with 3 additions and 3 deletions

View file

@ -185,7 +185,7 @@ describe('History', () => {
const entry = await historyService.createOrUpdateHistoryEntry(note2, user);
expect(entry.pinStatus).toBeFalsy();
await request(app.getHttpServer())
.put(`/me/history/${entry.note.alias}`)
.put(`/me/history/${entry.note.alias || 'undefined'}`)
.send({ pinStatus: true })
.expect(200);
const userEntries = await historyService.getEntriesByUser(user);
@ -199,7 +199,7 @@ describe('History', () => {
const entry2 = await historyService.createOrUpdateHistoryEntry(note, user);
const entryDto = historyService.toHistoryEntryDto(entry2);
await request(app.getHttpServer())
.delete(`/me/history/${entry.note.alias}`)
.delete(`/me/history/${entry.note.alias || 'undefined'}`)
.expect(200);
const userEntries = await historyService.getEntriesByUser(user);
expect(userEntries.length).toEqual(1);

View file

@ -134,7 +134,7 @@ describe('Media', () => {
'hardcoded',
'test_upload_media',
);
const filename = url.split('/').pop();
const filename = url.split('/').pop() || '';
await request(app.getHttpServer())
.delete('/media/' + filename)
.expect(204);