Browse Source

prove issue 595 is fixed

Adam Shaw 11 years ago
parent
commit
7cbac28270
1 changed files with 13 additions and 0 deletions
  1. 13 0
      tests/automated/events-function.js

+ 13 - 0
tests/automated/events-function.js

@@ -118,4 +118,17 @@ describe('events as a function', function() {
 		$('#cal').fullCalendar(options);
 	});
 
+	it('requests the correct dates when days at the start/end of the month are hidden', function(done) {
+		options.currentView = 'month';
+		options.defaultDate = '2013-06-01'; // June 2013 has first day as Saturday, and last as Sunday!
+		options.weekends = false;
+		options.weekMode = 'variable';
+		options.events = function(start, end, timezone, callback) {
+			expect(start).toEqualMoment('2013-06-03');
+			expect(end).toEqualMoment('2013-06-29');
+			done();
+		};
+		$('#cal').fullCalendar(options);
+	});
+
 });