Mercurial > p > roundup > code
diff test/rest_common.py @ 5645:7f4d19867123
Make print into function call for python3 compatibility.
| author | John Rouillard <rouilj@ieee.org> |
|---|---|
| date | Sun, 10 Mar 2019 18:09:35 -0400 |
| parents | a60cbbcc9309 |
| children | 095db27e8064 |
line wrap: on
line diff
--- a/test/rest_common.py Sun Mar 10 17:57:26 2019 -0400 +++ b/test/rest_common.py Sun Mar 10 18:09:35 2019 -0400 @@ -97,7 +97,7 @@ self.assertEqual(self.dummy_client.response_code, 200) self.assertEqual(len(results['data']['collection']), 3) self.assertEqual(results['data']['@total_size'], 3) - print self.dummy_client.additional_headers["X-Count-Total"] + print(self.dummy_client.additional_headers["X-Count-Total"]) self.assertEqual( self.dummy_client.additional_headers["X-Count-Total"], "3" @@ -368,25 +368,25 @@ ] if mode == 'header': - print "Mode = %s"%mode + print("Mode = %s"%mode) self.headers = {'etag': etag} elif mode == 'etag': - print "Mode = %s"%mode + print("Mode = %s"%mode) form.list.append(cgi.MiniFieldStorage('@etag', etag)) elif mode == 'both': - print "Mode = %s"%mode + print("Mode = %s"%mode) self.headers = {'etag': etag} form.list.append(cgi.MiniFieldStorage('@etag', etag)) elif mode == 'brokenheader': - print "Mode = %s"%mode + print("Mode = %s"%mode) self.headers = {'etag': 'bad'} form.list.append(cgi.MiniFieldStorage('@etag', etag)) elif mode == 'brokenetag': - print "Mode = %s"%mode + print("Mode = %s"%mode) self.headers = {'etag': etag} form.list.append(cgi.MiniFieldStorage('@etag', 'bad')) elif mode == 'none': - print "Mode = %s"%mode + print( "Mode = %s"%mode) else: self.fail("unknown mode found") @@ -571,7 +571,6 @@ form = cgi.FieldStorage(body_file, headers=headers, environ=env) - print form self.server.client.request.headers.getheader=self.get_header results = self.server.dispatch('POST', "/rest/data/issue",
