From 43705d84d64ac5101ebc580cc7b911bf9699d5f3 Mon Sep 17 00:00:00 2001 From: Kenneth Reitz Date: Mon, 15 May 2017 20:05:00 -0400 Subject: [PATCH] test intervals --- test_maya.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/test_maya.py b/test_maya.py index c5fff4c..9f6c296 100644 --- a/test_maya.py +++ b/test_maya.py @@ -202,3 +202,9 @@ def test_comparison_operations(): now > 1 with pytest.raises(TypeError): now >= 1 + +def test_intervals(): + now = maya.now() + tomorrow = now.add(days=1) + + assert len(list(maya.intervals(now, tomorrow, 60*60))) == 24