From 3876fca68326ae940bcd3732a50a836a1b76e637 Mon Sep 17 00:00:00 2001
From: Piotr Gawron <piotr.gawron@uni.lu>
Date: Mon, 8 Jan 2018 16:20:25 +0100
Subject: [PATCH] dates in unit test fixed

---
 smash/web/tests/test_statistics.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/smash/web/tests/test_statistics.py b/smash/web/tests/test_statistics.py
index 92e19cf5..3c36dcf7 100644
--- a/smash/web/tests/test_statistics.py
+++ b/smash/web/tests/test_statistics.py
@@ -34,13 +34,13 @@ class TestStatistics(TestCase):
         self.assertEqual(12, previous_month)
 
     def test_get_statistics_for_month_one_appointment(self):
-        statistics = self.statistics_manager.get_statistics_for_month(self.visit_start.month, self.now.year)
+        statistics = self.statistics_manager.get_statistics_for_month(self.visit_start.month, self.visit_start.year)
         self.check_statistics(statistics, 1, 0, 0, {"C": [0, 0]}, ['Scheduled'])
 
         statistics = self.statistics_manager.get_statistics_for_month(self.now.month, self.now.year)
         self.check_statistics(statistics, 0, 0, 1, {"C": [1, 1]}, ['Scheduled'])
 
-        statistics = self.statistics_manager.get_statistics_for_month(self.visit_end.month, self.now.year)
+        statistics = self.statistics_manager.get_statistics_for_month(self.visit_end.month, self.visit_end.year)
         self.check_statistics(statistics, 0, 1, 0, {"C": [0, 0]}, ['Scheduled'])
 
     def test_get_statistics_for_month_one_appointment_visit(self):
-- 
GitLab