recurring.js 880 B

1234567891011121314151617181920212223242526272829303132333435
  1. describe('recurring events', function() {
  2. describe('when timed events in local timezone', function() {
  3. pushOptions({
  4. defaultView: 'agendaWeek',
  5. defaultDate: '2017-07-03',
  6. timezone: 'local',
  7. events: [
  8. { start: '09:00', end: '11:00', dow: [ 2, 4 ] }
  9. ]
  10. })
  11. it('expands events with local time', function() {
  12. initCalendar()
  13. var events = currentCalendar.clientEvents()
  14. expect(events[0].start.format()).toBe(
  15. moment('2017-07-04T09:00:00').format() // local
  16. )
  17. expect(events[0].end.format()).toBe(
  18. moment('2017-07-04T11:00:00').format() // local
  19. )
  20. expect(events[1].start.format()).toBe(
  21. moment('2017-07-06T09:00:00').format() // local
  22. )
  23. expect(events[1].end.format()).toBe(
  24. moment('2017-07-06T11:00:00').format() // local
  25. )
  26. })
  27. })
  28. })