From 6459e3d7b9479167f071db1895082686fc2b8f66 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Wed, 3 Jun 2015 16:02:23 +0200 Subject: php-zetacomponents-unit-test: 1.0.2 - New Package --- php-zetacomponents-unit-test-pr5.patch | 55 ++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 php-zetacomponents-unit-test-pr5.patch (limited to 'php-zetacomponents-unit-test-pr5.patch') diff --git a/php-zetacomponents-unit-test-pr5.patch b/php-zetacomponents-unit-test-pr5.patch new file mode 100644 index 0000000..b3a211f --- /dev/null +++ b/php-zetacomponents-unit-test-pr5.patch @@ -0,0 +1,55 @@ +From e310f21a220f8e52d5ef86d2474bd2fbeeb82e25 Mon Sep 17 00:00:00 2001 +From: Remi Collet +Date: Wed, 3 Jun 2015 15:00:36 +0200 +Subject: [PATCH] fix ezcTestConstraintSimilarImage for recent phpunit + +--- + src/constraint/image.php | 24 +++++------------------- + 1 file changed, 5 insertions(+), 19 deletions(-) + +diff --git a/src/constraint/image.php b/src/constraint/image.php +index be037c5..7c837ab 100644 +--- a/src/constraint/image.php ++++ b/src/constraint/image.php +@@ -154,36 +154,22 @@ public function evaluate( $other, $description = '', $returnResult = false ) + * @param boolean $not Flag to indicate negation. + * @throws PHPUnit_Framework_ExpectationFailedException + */ +- public function fail( $other, $description, PHPUnit_Framework_ComparisonFailure $comparisonFailure = NULL ) ++ public function fail( $other, $description, SebastianBergmann\Comparator\ComparisonFailure $comparisonFailure = NULL ) + { + $failureDescription = sprintf( + 'Failed asserting that image "%s" is similar to image "%s".', +- + $other, + $this->filename + ); + +- if ($not) { +- $failureDescription = self::negate($failureDescription); +- } +- + if (!empty($description)) { + $failureDescription = $description . "\n" . $failureDescription; + } + +- if (!$not) { +- throw new PHPUnit_Framework_ExpectationFailedException( +- $failureDescription, +- PHPUnit_Framework_ComparisonFailure::diffEqual( +- $this->delta, +- $this->difference +- ) +- ); +- } else { +- throw new PHPUnit_Framework_ExpectationFailedException( +- $failureDescription +- ); +- } ++ throw new PHPUnit_Framework_ExpectationFailedException( ++ $failureDescription, ++ $comparisonFailure ++ ); + } + + /** -- cgit