@@ -52,17 +52,17 @@ def _makeHTTP(self, *args, **kw):
5252 def test_ctor_default (self , _ ):
5353 CREDENTIALS = _make_credentials ()
5454 target = self ._make_one (credentials = CREDENTIALS )
55- self .assertEquals (target .service , target .DEFAULT_SERVICE )
56- self .assertEquals (target .version , None )
55+ self .assertEqual (target .service , target .DEFAULT_SERVICE )
56+ self .assertEqual (target .version , None )
5757
5858 def test_ctor_params (self ):
5959 CREDENTIALS = _make_credentials ()
6060 target = self ._make_one (project = self .PROJECT ,
6161 credentials = CREDENTIALS ,
6262 service = self .SERVICE ,
6363 version = self .VERSION )
64- self .assertEquals (target .service , self .SERVICE )
65- self .assertEquals (target .version , self .VERSION )
64+ self .assertEqual (target .service , self .SERVICE )
65+ self .assertEqual (target .version , self .VERSION )
6666
6767 def test_report_exception_with_gax (self ):
6868 CREDENTIALS = _make_credentials ()
@@ -77,7 +77,7 @@ def test_report_exception_with_gax(self):
7777 except NameError :
7878 target .report_exception ()
7979 payload = make_api .return_value .report_error_event .call_args [0 ][0 ]
80- self .assertEquals (payload ['serviceContext' ], {
80+ self .assertEqual (payload ['serviceContext' ], {
8181 'service' : target .DEFAULT_SERVICE ,
8282 })
8383 self .assertIn ('test_report' , payload ['message' ])
@@ -99,7 +99,7 @@ def test_report_exception_wo_gax(self):
9999 mock_report = _error_api .return_value .report_error_event
100100 payload = mock_report .call_args [0 ][0 ]
101101
102- self .assertEquals (payload ['serviceContext' ], {
102+ self .assertEqual (payload ['serviceContext' ], {
103103 'service' : target .DEFAULT_SERVICE ,
104104 })
105105 self .assertIn ('test_report' , payload ['message' ])
@@ -129,19 +129,19 @@ def test_report_exception_with_service_version_in_constructor(
129129 target .report_exception (http_context = http_context , user = USER )
130130
131131 payload = client .report_error_event .call_args [0 ][0 ]
132- self .assertEquals (payload ['serviceContext' ], {
132+ self .assertEqual (payload ['serviceContext' ], {
133133 'service' : SERVICE ,
134134 'version' : VERSION
135135 })
136136 self .assertIn (
137137 'test_report_exception_with_service_version_in_constructor' ,
138138 payload ['message' ])
139139 self .assertIn ('test_client.py' , payload ['message' ])
140- self .assertEquals (
140+ self .assertEqual (
141141 payload ['context' ]['httpContext' ]['responseStatusCode' ], 500 )
142- self .assertEquals (
142+ self .assertEqual (
143143 payload ['context' ]['httpContext' ]['method' ], 'GET' )
144- self .assertEquals (payload ['context' ]['user' ], USER )
144+ self .assertEqual (payload ['context' ]['user' ], USER )
145145
146146 @mock .patch ('google.cloud.error_reporting.client.make_report_error_api' )
147147 def test_report (self , make_client ):
@@ -157,7 +157,7 @@ def test_report(self, make_client):
157157
158158 payload = client .report_error_event .call_args [0 ][0 ]
159159
160- self .assertEquals (payload ['message' ], MESSAGE )
160+ self .assertEqual (payload ['message' ], MESSAGE )
161161 report_location = payload ['context' ]['reportLocation' ]
162162 self .assertIn ('test_client.py' , report_location ['filePath' ])
163163 self .assertEqual (report_location ['functionName' ], 'test_report' )
0 commit comments