Added edit mode
This commit is contained in:
@@ -10,6 +10,7 @@ const DAY = {
|
||||
status: 'closed',
|
||||
lunchType: 'restaurant',
|
||||
restaurant: 'Le Relais',
|
||||
startedTs: at('07:30'),
|
||||
endedTs: at('17:30'),
|
||||
};
|
||||
|
||||
@@ -39,6 +40,7 @@ describe('buildResume', () => {
|
||||
it('keeps lunch out of the worked total', () => {
|
||||
const r = buildResume(DAY, ENTRIES, 15);
|
||||
expect(r.workedMs).toBe(9 * 60 * MINUTE); // 09h00 on site, lunch excluded
|
||||
expect(r.totalMs).toBe(10 * 60 * MINUTE);
|
||||
expect(r.lunch).toEqual({ type: 'restaurant', restaurant: 'Le Relais', ms: 60 * MINUTE });
|
||||
});
|
||||
|
||||
@@ -91,7 +93,8 @@ describe('resumeToText', () => {
|
||||
'',
|
||||
'Déjeuner : restaurant (Le Relais), 1h00',
|
||||
'',
|
||||
'Total travaillé : 9h00',
|
||||
'Travail hors repas : 9h00',
|
||||
'Total journée (repas compris) : 10h00',
|
||||
].join('\n'),
|
||||
);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user