Skip to content

Commit d8c00e6

Browse files
committed
Calendar test improved to support recurrence pattern
1 parent 0771989 commit d8c00e6

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

test/calendar-test.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import * as requests from '../src/model/requests/requests';
22
import uuidv4 from 'uuid/v4';
33
import * as models from '../src/model/model';
4+
import {DailyRecurrencePatternDto} from '../src/model/model';
45
import 'mocha';
56
import {expect} from 'chai';
67
import {suiteBase} from "./suite-base";
@@ -125,6 +126,8 @@ describe('Calendar tests', function () {
125126
const mapiCalendarDto = await td.api().convertCalendarModelToMapiModel(
126127
new requests.ConvertCalendarModelToMapiModelRequest(calendarDto));
127128
expect(calendarDto.location).to.be.eq(mapiCalendarDto.body.location);
129+
expect('MapiCalendarDailyRecurrencePatternDto').to.be.eq(
130+
mapiCalendarDto.body.recurrence.recurrencePattern.discriminator);
128131
});
129132

130133
function getCalendarDto(): models.CalendarDto {
@@ -138,7 +141,7 @@ describe('Calendar tests', function () {
138141
calendar.startDate = td.getDate(undefined, 1);
139142
calendar.endDate = td.getDate(calendar.startDate, 1);
140143
calendar.location = 'Some location';
141-
144+
calendar.recurrence = new DailyRecurrencePatternDto(undefined, 10, undefined, "Monday");
142145
return calendar;
143146
}
144147
});

0 commit comments

Comments
 (0)