Commit fe3f7806 authored by Aurel's avatar Aurel

fix assertRegex and remove print

parent 61dd2329
......@@ -210,7 +210,6 @@ class KedifaMixinCaucase(KedifaMixin):
csr_id = output.split()[0].decode()
except IndexError:
self.fail('csr_id parse failed: %s' % (output,))
print("%r %r %r" %(self.cas, csr_id, kedifa_key_pem))
caucase.cli.main(argv=self.cas + [
'--get-crt', csr_id, kedifa_key_pem
])
......@@ -272,12 +271,12 @@ class KedifaMixinCaucase(KedifaMixin):
six.moves.http_client.CREATED
)
location = result.headers.get('Location', '')
self.assertRegex(
self.assertRegexpMatches(
location,
r'^/[a-z0-9]{32}$'
)
reserved_reference = result.text
self.assertRegex(
self.assertRegexpMatches(
reserved_reference,
r'^[a-z0-9]{32}$'
)
......@@ -884,7 +883,7 @@ class KedifaIntegrationTest(KedifaMixinCaucase, unittest.TestCase):
def test_GET_generateauth(self):
auth = self.generateauth()
self.assertRegex(
self.assertRegexpMatches(
auth,
r'^[a-z0-9]{32}$'
)
......@@ -929,7 +928,7 @@ class KedifaIntegrationTest(KedifaMixinCaucase, unittest.TestCase):
'',
result.text
)
self.assertRegex(
self.assertRegexpMatches(
result.headers.get('Location', ''),
r'^/%s/\d+$' % key
)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment