summaryrefslogtreecommitdiffstats
path: root/ipatests/test_integration
diff options
context:
space:
mode:
authorOleg Fayans <ofayans@redhat.com>2016-09-21 14:12:10 +0200
committerDavid Kupka <dkupka@redhat.com>2016-09-22 15:20:42 +0200
commit804aae81966f23e307ec86364489f808fd0c3357 (patch)
treeac1d85dcd46b1496cca73623d00dfd2df0ead151 /ipatests/test_integration
parentb8cf212e8bbe301f6d44551ecac063d12a042520 (diff)
downloadfreeipa-804aae81966f23e307ec86364489f808fd0c3357.tar.gz
freeipa-804aae81966f23e307ec86364489f808fd0c3357.tar.xz
freeipa-804aae81966f23e307ec86364489f808fd0c3357.zip
tests: fixed expects of incorrect error messages
Reviewed-By: David Kupka <dkupka@redhat.com>
Diffstat (limited to 'ipatests/test_integration')
-rw-r--r--ipatests/test_integration/test_caless.py56
1 files changed, 24 insertions, 32 deletions
diff --git a/ipatests/test_integration/test_caless.py b/ipatests/test_integration/test_caless.py
index f362517f2..f499c61f3 100644
--- a/ipatests/test_integration/test_caless.py
+++ b/ipatests/test_integration/test_caless.py
@@ -353,9 +353,7 @@ class TestServerInstall(CALessBase):
result = self.install_server()
assert_error(result,
- 'server.p12 is not signed by root.pem, or the full '
- 'certificate chain is not present in the PKCS#12 '
- 'file')
+ 'The full certificate chain is not present in server.p12')
@server_install_teardown
def test_ca_server_cert(self):
@@ -367,8 +365,7 @@ class TestServerInstall(CALessBase):
result = self.install_server()
assert_error(result,
- 'trust chain of the server certificate in server.p12 '
- 'contains 1 certificates, expected 2')
+ 'The full certificate chain is not present in server.p12')
@pytest.mark.xfail(reason='Ticket N 6289')
@server_install_teardown
@@ -598,9 +595,9 @@ class TestServerInstall(CALessBase):
result = self.install_server(http_pkcs12='http.p12',
dirsrv_pkcs12='dirsrv.p12')
- assert_error(result,
- 'http.p12 is not signed by root.pem, or the full '
- 'certificate chain is not present in the PKCS#12 file')
+ assert_error(result, 'Apache Server SSL certificate and'
+ ' Directory Server SSL certificate are not'
+ ' signed by the same CA certificate')
@server_install_teardown
def test_ds_intermediate_ca(self):
@@ -614,8 +611,8 @@ class TestServerInstall(CALessBase):
result = self.install_server(http_pkcs12='http.p12',
dirsrv_pkcs12='dirsrv.p12')
assert_error(result,
- 'dirsrv.p12 is not signed by root.pem, or the full '
- 'certificate chain is not present in the PKCS#12 file')
+ 'Apache Server SSL certificate and Directory Server SSL'
+ ' certificate are not signed by the same CA certificate')
@server_install_teardown
def test_ca_self_signed(self):
@@ -712,7 +709,7 @@ class TestServerInstall(CALessBase):
stdin_text=stdin_text)
assert result.returncode == 0
self.verify_installation()
- assert ('Enter server.p12 unlock password:'
+ assert ('Enter Apache Server private key unlock password'
in result.stdout_text), result.stdout_text
@server_install_teardown
@@ -729,7 +726,7 @@ class TestServerInstall(CALessBase):
stdin_text=stdin_text)
assert result.returncode == 0
self.verify_installation()
- assert ('Enter server.p12 unlock password:'
+ assert ('Enter Directory Server private key unlock password'
in result.stdout_text), result.stdout_text
@server_install_teardown
@@ -782,11 +779,10 @@ class TestReplicaInstall(CALessBase):
result = self.master.run_command(['ipa-replica-prepare',
self.replicas[0].hostname],
raiseonerr=False)
- assert result.returncode > 0
- assert ('Cannot issue certificates: a CA is not installed. Use the '
- '--http-cert-file, --dirsrv-cert-file options to provide '
- 'custom certificates.' in result.stderr_text), \
- result.stderr_text
+ assert_error(result, "Cannot issue certificates: a CA is not "
+ "installed. Use the --http-cert-file, "
+ "--dirsrv-cert-file options to provide "
+ "custom certificates.")
@replica_install_teardown
def test_nonexistent_http_pkcs12_file(self):
@@ -840,9 +836,9 @@ class TestReplicaInstall(CALessBase):
result = self.prepare_replica(http_pkcs12='http.p12',
dirsrv_pkcs12='dirsrv.p12')
- assert_error(result,
- 'http.p12 is not signed by /etc/ipa/ca.crt, or the full '
- 'certificate chain is not present in the PKCS#12 file')
+ assert_error(result, 'Apache Server SSL certificate and'
+ ' Directory Server SSL certificate are not'
+ ' signed by the same CA certificate')
@replica_install_teardown
def test_ds_unknown_ca(self):
@@ -854,9 +850,8 @@ class TestReplicaInstall(CALessBase):
result = self.prepare_replica(http_pkcs12='http.p12',
dirsrv_pkcs12='dirsrv.p12')
assert_error(result,
- 'dirsrv.p12 is not signed by /etc/ipa/ca.crt, or the '
- 'full certificate chain is not present in the PKCS#12 '
- 'file')
+ 'Apache Server SSL certificate and Directory Server SSL'
+ ' certificate are not signed by the same CA certificate')
@replica_install_teardown
def test_invalid_http_cn(self):
@@ -982,8 +977,8 @@ class TestReplicaInstall(CALessBase):
result = self.prepare_replica(http_pkcs12='http.p12',
dirsrv_pkcs12='dirsrv.p12')
assert_error(result,
- 'http.p12 is not signed by /etc/ipa/ca.crt, or the full '
- 'certificate chain is not present in the PKCS#12 file')
+ 'Apache Server SSL certificate and Directory Server SSL'
+ ' certificate are not signed by the same CA certificate')
@replica_install_teardown
def test_ds_intermediate_ca(self):
@@ -994,10 +989,9 @@ class TestReplicaInstall(CALessBase):
result = self.prepare_replica(http_pkcs12='http.p12',
dirsrv_pkcs12='dirsrv.p12')
- assert_error(result,
- 'dirsrv.p12 is not signed by /etc/ipa/ca.crt, or the '
- 'full certificate chain is not present in the PKCS#12 '
- 'file')
+ assert_error(result, 'Apache Server SSL certificate and'
+ ' Directory Server SSL certificate are not'
+ ' signed by the same CA certificate')
@replica_install_teardown
def test_valid_certs(self):
@@ -1422,9 +1416,7 @@ class TestCertinstall(CALessBase):
result = self.certinstall('w', 'server-selfsign')
assert_error(result,
- 'server.p12 is not signed by /etc/ipa/ca.crt, or the '
- 'full certificate chain is not present in the PKCS#12 '
- 'file')
+ 'The full certificate chain is not present in server.p12')
def test_valid_http(self):
"Install new valid HTTP certificate"