Check if the file was created

This commit is contained in:
Ryan Mwangi 2024-10-29 21:40:57 +03:00
parent 8650d91edb
commit 4311619f64
1 changed files with 5 additions and 1 deletions

View File

@ -33,6 +33,10 @@ describe('Calendar Merging API', () => {
});
expect(response.status).toBe(200);
expect(response.body.url).toMatch(/calendar\/Date_Based_Calendar/);
})
// Check if the file was created
const filePath = path.join(MERGED_CALENDARS_DIR, 'Date_Based_Calendar.ics');
expect(fs.existsSync(filePath)).toBe(true);
});
});