ZF-11470: InfoCard XmlParsingTest has Invalid fail-testcase
Description
InfoCard's XmlParsingTest has below's code.
public function testKeyInfo() {
try {
Zend_InfoCard_Xml_KeyInfo::getInstance("");
$this->fail("Expected Exception Not thrown");
} catch(Exception $e) {
/* yay */
}
Zend_InfoCard_Xml_KeyInfo::getInstance() method will not throw Exception, if string is as argument?
Please evaluate this above testcase. Is "" valid for KeyInfo?(sorry, I can't judge.)
If "" is valid ,please write assert-testcase for "", and write remove failmethod above.
Comments
Posted by Pádraic Brady (padraic) on 2011-08-13T23:45:50.000+0000
The method actually checks for an XML DSig namespace in the given XML string later on and throws an Exception if not found. The test description sucks, but I think that's what it's verifying. Marking as a non-issue as a result.
Thanks for taking the time to report it though!