Fixed the way PHPUnit_Util_Configuration parses listener constructor arguments #594

Merged
merged 1 commit into from Jun 22, 2012

2 participants

@austinhyde

Previously, getListenerConfiguration assumed the element
would always be the second element (index 1) because nicely formatted
XML has a DOMText node containing a newline and some space before the
arguments node. Computer-generated XML places the arguments element
immediately after the listener element, so the node would be at index 0,
causing the arguments node to not be found.

Instead, it now searches the entire listener node for argument nodes.

@austinhyde austinhyde Fixed the way PHPUnit_Util_Configuration parses listener constructor …
…arguments

Previously, getListenerConfiguration assumed the <arguments> element
would always be the second element (index 1) because nicely formatted
XML has a DOMText node containing a newline and some space before the
arguments node. Computer-generated XML places the arguments element
immediately after the listener element, so the node would be at index 0,
causing the arguments node to not be found. Instead, it now searches
the entire listener node for argument nodes.
dd560a3
@sebastianbergmann sebastianbergmann merged commit d4efc6b into sebastianbergmann:3.6 Jun 22, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment