summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Kupka <dkupka@redhat.com>2016-06-28 10:47:10 +0200
committerMartin Basti <mbasti@redhat.com>2016-06-29 14:49:08 +0200
commit573819eb07ea67311004850b7726f3368bacb49b (patch)
tree3bb4c06ab4b678920c1c3ed2d830cec39d16f5f8
parent954f6095fd2783e631cba042f86bec87394f9224 (diff)
downloadfreeipa-573819eb07ea67311004850b7726f3368bacb49b.tar.gz
freeipa-573819eb07ea67311004850b7726f3368bacb49b.tar.xz
freeipa-573819eb07ea67311004850b7726f3368bacb49b.zip
test: cert: Reflect change in behavior in tests
Command cert-find with parameter sizelimit set to 0 no longer returns 0 certificates but returns all. More precise ConversionError is returned when parameter is not convertible to its type. https://fedorahosted.org/freeipa/ticket/5381 https://fedorahosted.org/freeipa/ticket/4739 Reviewed-By: Petr Spacek <pspacek@redhat.com>
-rw-r--r--ipatests/test_xmlrpc/test_cert_plugin.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/ipatests/test_xmlrpc/test_cert_plugin.py b/ipatests/test_xmlrpc/test_cert_plugin.py
index 1a6168da2..8127ef224 100644
--- a/ipatests/test_xmlrpc/test_cert_plugin.py
+++ b/ipatests/test_xmlrpc/test_cert_plugin.py
@@ -429,8 +429,9 @@ class test_cert_find(XMLRPC_test):
"""
Search with a sizelimit of 0
"""
+ count_all = api.Command['cert_find']()['count']
res = api.Command['cert_find'](sizelimit=0)
- assert 'count' in res and res['count'] == 0
+ assert 'count' in res and res['count'] == count_all
@raises(errors.ValidationError)
def test_0028_find_negative_size(self):
@@ -453,7 +454,7 @@ class test_cert_find(XMLRPC_test):
res = api.Command['cert_find'](subject=u'ipatestcert.%s' % api.env.domain)
assert 'count' in res and res['count'] >= 1
- @raises(errors.ValidationError)
+ @raises(errors.ConversionError)
def test_0031_search_on_invalid_date(self):
"""
Search using invalid date format