From 128be1ef34d5a342fee0ac7d9e067471dd55c805 Mon Sep 17 00:00:00 2001 From: Saurabh Kumar <theskumar@users.noreply.github.com> Date: Tue, 26 Jul 2022 17:12:50 +0530 Subject: [PATCH] =?UTF-8?q?Replace=20=E2=80=9Cself.assertEquals=E2=80=9D?= =?UTF-8?q?=20with=20=E2=80=9Cself.assertEqual=E2=80=9D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hypha/apply/dashboard/tests/test_views.py | 10 +++++----- hypha/apply/funds/tests/test_views.py | 2 +- hypha/apply/projects/tests/test_models.py | 6 +++--- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/hypha/apply/dashboard/tests/test_views.py b/hypha/apply/dashboard/tests/test_views.py index 2625333a0..4f1fc1ae0 100644 --- a/hypha/apply/dashboard/tests/test_views.py +++ b/hypha/apply/dashboard/tests/test_views.py @@ -86,7 +86,7 @@ class TestStaffDashboard(BaseViewTestCase): response = self.get_page() self.assertContains(response, 'Waiting for your review') self.assertContains(response, submission.title) - self.assertEquals(response.context['awaiting_reviews']['count'], 1) + self.assertEqual(response.context['awaiting_reviews']['count'], 1) def test_waiting_for_review_after_agreement_is_empty(self): staff = StaffFactory() @@ -96,7 +96,7 @@ class TestStaffDashboard(BaseViewTestCase): response = self.get_page() self.assertContains(response, 'Waiting for your review') self.assertContains(response, "Nice! You're all caught up.") - self.assertEquals(response.context['awaiting_reviews']['count'], 0) + self.assertEqual(response.context['awaiting_reviews']['count'], 0) def test_active_invoices_with_no_project(self): response = self.get_page() @@ -181,19 +181,19 @@ class TestReviewerDashboard(BaseViewTestCase): response = self.get_page() self.assertContains(response, 'Waiting for your review') self.assertContains(response, submission.title) - self.assertEquals(response.context['in_review_count'], 1) + self.assertEqual(response.context['in_review_count'], 1) def test_no_submissions_waiting_for_review(self): submission = ApplicationSubmissionFactory(status='external_review', workflow_stages=2, reviewers=[]) response = self.get_page() self.assertNotContains(response, submission.title) - self.assertEquals(response.context['in_review_count'], 0) + self.assertEqual(response.context['in_review_count'], 0) def test_submission_assigned_but_not_in_external_review_status(self): submission = ApplicationSubmissionFactory(status='concept_review_discussion', workflow_stages=2, reviewers=[self.user]) response = self.get_page() self.assertNotContains(response, submission.title) - self.assertEquals(response.context['in_review_count'], 0) + self.assertEqual(response.context['in_review_count'], 0) class TestAdminDashboard(BaseViewTestCase): diff --git a/hypha/apply/funds/tests/test_views.py b/hypha/apply/funds/tests/test_views.py index 9ab145df8..349d72e44 100644 --- a/hypha/apply/funds/tests/test_views.py +++ b/hypha/apply/funds/tests/test_views.py @@ -245,7 +245,7 @@ class TestStaffSubmissionView(BaseSubmissionViewTestCase): submission = ApplicationSubmission.objects.get(pk=self.submission.pk) self.assertTrue(hasattr(submission, 'project')) - self.assertEquals(submission.project.id, project.id) + self.assertEqual(submission.project.id, project.id) def test_can_see_add_determination_primary_action(self): def assert_add_determination_displayed(submission, button_text): diff --git a/hypha/apply/projects/tests/test_models.py b/hypha/apply/projects/tests/test_models.py index 92c442a37..8fd8d9fe0 100644 --- a/hypha/apply/projects/tests/test_models.py +++ b/hypha/apply/projects/tests/test_models.py @@ -50,9 +50,9 @@ class TestProjectModel(TestCase): project = Project.create_from_submission(submission) - self.assertEquals(project.submission, submission) - self.assertEquals(project.title, submission.title) - self.assertEquals(project.user, submission.user) + self.assertEqual(project.submission, submission) + self.assertEqual(project.title, submission.title) + self.assertEqual(project.user, submission.user) def test_get_missing_document_categories_with_enough_documents(self): project = ProjectFactory() -- GitLab