Re: [Freeipa-devel] [PATCH 0004] [Test] Test for caacl-add-service: incorrect error message when service does not exists
On 18.08.2016 15:02, Tomas Krizek wrote: Hi, NACK. The issue is not that the error message contains the "no such entry" string. That is actually a valid part of the error message if the service indeed does not exist. The problem is that the error message contained only the first character of the service's name instead of the entire name of the service. For example, the command ipa caacl-add-service test_caacl --services svc/master2.ipa.test --services svc/master1.ipa.test should end with these error messages if those services do not exist: member service:svc/master2.ipa.t...@ipa.test: no such entry member service:svc/master1.ipa.t...@ipa.test: no such entry There is also a typo in the file name of the test and I'm also not sure if there isn't a better place to put the test. +1 This should not be integration_test but only test_xmlrpc Martin^2 On 08/18/2016 01:48 PM, Ganna Kaihorodova wrote: Hello! Test for caacl-add-service: incorrect error message when service does not exists https://fedorahosted.org/freeipa/ticket/6171 Best regards, Ganna Kaihorodova Associate Software Quality Engineer : -- Tomas Krizek -- Manage your subscription for the Freeipa-devel mailing list: https://www.redhat.com/mailman/listinfo/freeipa-devel Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code
Re: [Freeipa-devel] [PATCH 0004] [Test] Test for caacl-add-service: incorrect error message when service does not exists
Hi, NACK. The issue is not that the error message contains the "no such entry" string. That is actually a valid part of the error message if the service indeed does not exist. The problem is that the error message contained only the first character of the service's name instead of the entire name of the service. For example, the command ipa caacl-add-service test_caacl --services svc/master2.ipa.test --services svc/master1.ipa.test should end with these error messages if those services do not exist: member service: svc/master2.ipa.t...@ipa.test: no such entry member service: svc/master1.ipa.t...@ipa.test: no such entry There is also a typo in the file name of the test and I'm also not sure if there isn't a better place to put the test. On 08/18/2016 01:48 PM, Ganna Kaihorodova wrote: Hello! Test for caacl-add-service: incorrect error message when service does not exists https://fedorahosted.org/freeipa/ticket/6171 Best regards, Ganna Kaihorodova Associate Software Quality Engineer : -- Tomas Krizek -- Manage your subscription for the Freeipa-devel mailing list: https://www.redhat.com/mailman/listinfo/freeipa-devel Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code
[Freeipa-devel] [PATCH 0004] [Test] Test for caacl-add-service: incorrect error message when service does not exists
Hello! Test for caacl-add-service: incorrect error message when service does not exists https://fedorahosted.org/freeipa/ticket/6171 Best regards, Ganna Kaihorodova Associate Software Quality Engineer :From 837d85f0b3e8544a983e1ceeb770712807c0f0cf Mon Sep 17 00:00:00 2001 From: Ganna KaihorodovaDate: Thu, 18 Aug 2016 11:16:49 +0200 Subject: [PATCH] Test for caacl-add-service Test for caacl-add-service: incorrect error message when service does not exists https://fedorahosted.org/freeipa/ticket/6171 --- ipatests/test_integration/test_caal_message.py | 20 1 file changed, 20 insertions(+) create mode 100644 ipatests/test_integration/test_caal_message.py diff --git a/ipatests/test_integration/test_caal_message.py b/ipatests/test_integration/test_caal_message.py new file mode 100644 index ..d9c5d4e5b74aeec87b6985ed94a69bcc9d9435ff --- /dev/null +++ b/ipatests/test_integration/test_caal_message.py @@ -0,0 +1,20 @@ +from ipatests.test_integration.base import IntegrationTest + + +class TestIncorrectErrorMessage(IntegrationTest): + +"https://fedorahosted.org/freeipa/ticket/6171; + +topology = 'star' +num_replicas = 0 +caacl = 'test_caacl' + +def test_errormsg(self): +master = self.master +master.run_command("ipa caacl-add %s --desc \"test\"" % self.caacl) +result = master.run_command( +"ipa caacl-add-service %s --services" +"svc/`hostname`" % self.caacl, raiseonerr=False +) +assert("no such entry" not in result.stderr_text), ( +"Wrong error message") -- 2.7.4 -- Manage your subscription for the Freeipa-devel mailing list: https://www.redhat.com/mailman/listinfo/freeipa-devel Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code