Skip to content

Commit

Permalink
Replace self.assertEquals with self.assertEqual
Browse files Browse the repository at this point in the history
  • Loading branch information
norkans7 committed Dec 5, 2023
1 parent f7289e5 commit fff6b83
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions test_runner/blog/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -1140,9 +1140,9 @@ def setUp(self):

def test_value_from_view(self):
context = dict(view=self.read_view, object=self.post)
self.assertEquals(self.post.title, get_value_from_view(context, "title"))
self.assertEqual(self.post.title, get_value_from_view(context, "title"))
local_created = self.post.created_on.replace(tzinfo=tzone.utc).astimezone(ZoneInfo("Africa/Kigali"))
self.assertEquals(local_created.strftime("%b %d, %Y %H:%M"), get_value_from_view(context, "created_on"))
self.assertEqual(local_created.strftime("%b %d, %Y %H:%M"), get_value_from_view(context, "created_on"))

def test_view_as_json(self):
self.list_view.object_list = Post.objects.all()
Expand Down Expand Up @@ -1184,7 +1184,7 @@ def test_gmail_time(self):

# but a different year is different
jan_2 = datetime(2012, 1, 2, 17, 5, 0, 0).replace(tzinfo=tzone.utc)
self.assertEquals("2/1/12", gmail_time(jan_2, now))
self.assertEqual("2/1/12", gmail_time(jan_2, now))

def test_user_as_string(self):
# plain user have both first and last names
Expand Down

0 comments on commit fff6b83

Please sign in to comment.