From f6442c5c0c2b27544ebdaee1e8e9b3cc6d2c23ea Mon Sep 17 00:00:00 2001 From: = Date: Thu, 25 Apr 2024 16:17:42 -0300 Subject: [PATCH] fixing tests --- metrics/tests.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/metrics/tests.py b/metrics/tests.py index 7c562d7..39bdea3 100644 --- a/metrics/tests.py +++ b/metrics/tests.py @@ -8,7 +8,7 @@ from .views import get_metrics_and_aggregate_per_project from django.urls import reverse from django.contrib.auth.models import Permission -from datetime import datetime, timedelta +from datetime import datetime, timedelta, date from metrics.templatetags.metricstags import categorize, perc, bool_yesno, is_yesno from django.utils.translation import gettext_lazy as _ @@ -610,7 +610,7 @@ def test_export_trimester_report_exports_activities_results_with_number_when_som report = Report.objects.create(description="Report 1", created_by=self.user_profile, modified_by=self.user_profile, - initial_date=datetime.now().date(), + initial_date=date(2024, 2, 29), learning="Learnings!" * 51, activity_associated=self.activity, area_responsible=area_reponsible, @@ -646,7 +646,7 @@ def test_export_trimester_report_exports_activities_results_of_main_funding_proj report = Report.objects.create(description="Report 1", created_by=self.user_profile, modified_by=self.user_profile, - initial_date=datetime.now().date(), + initial_date=date(2024, 2, 29), learning="Learnings!" * 51, activity_associated=self.activity, area_responsible=area_reponsible, @@ -683,7 +683,7 @@ def test_export_trimester_report_by_area_succeds_if_user_is_authenticated(self): report = Report.objects.create(description="Report 1", created_by=self.user_profile, modified_by=self.user_profile, - initial_date=datetime.now().date(), + initial_date=date(2024, 2, 29), learning="Learnings!" * 51, activity_associated=self.activity, area_responsible=area_reponsible, @@ -730,7 +730,7 @@ def test_export_trimester_report_exports_wiki_links_as_wikitext(self): report = Report.objects.create(description="Report 1", created_by=self.user_profile, modified_by=self.user_profile, - initial_date=datetime.now().date(), + initial_date=date(2024, 2, 29), learning="Learnings!" * 51, activity_associated=self.activity, area_responsible=area_reponsible, @@ -766,7 +766,7 @@ def test_export_trimester_report_exports_wiki_links_as_wikitext_and_deals_with_d report = Report.objects.create(description="Report 1", created_by=self.user_profile, modified_by=self.user_profile, - initial_date=datetime.now().date(), + initial_date=date(2024, 2, 29), learning="Learnings!" * 51, activity_associated=self.activity, area_responsible=area_reponsible, @@ -774,7 +774,7 @@ def test_export_trimester_report_exports_wiki_links_as_wikitext_and_deals_with_d report_2 = Report.objects.create(description="Report 2", created_by=self.user_profile, modified_by=self.user_profile, - initial_date=datetime.now().date(), + initial_date=date(2024, 2, 29), learning="Learnings!" * 51, activity_associated=self.activity, area_responsible=area_reponsible,