Version 1
[yaffs-website] / vendor / phpunit / phpunit / src / Framework / ExpectationFailedException.php
diff --git a/vendor/phpunit/phpunit/src/Framework/ExpectationFailedException.php b/vendor/phpunit/phpunit/src/Framework/ExpectationFailedException.php
new file mode 100644 (file)
index 0000000..60229a9
--- /dev/null
@@ -0,0 +1,41 @@
+<?php
+/*
+ * This file is part of PHPUnit.
+ *
+ * (c) Sebastian Bergmann <sebastian@phpunit.de>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+/**
+ * Exception for expectations which failed their check.
+ *
+ * The exception contains the error message and optionally a
+ * SebastianBergmann\Comparator\ComparisonFailure which is used to
+ * generate diff output of the failed expectations.
+ *
+ * @since Class available since Release 3.0.0
+ */
+class PHPUnit_Framework_ExpectationFailedException extends PHPUnit_Framework_AssertionFailedError
+{
+    /**
+     * @var SebastianBergmann\Comparator\ComparisonFailure
+     */
+    protected $comparisonFailure;
+
+    public function __construct($message, SebastianBergmann\Comparator\ComparisonFailure $comparisonFailure = null, Exception $previous = null)
+    {
+        $this->comparisonFailure = $comparisonFailure;
+
+        parent::__construct($message, 0, $previous);
+    }
+
+    /**
+     * @return SebastianBergmann\Comparator\ComparisonFailure
+     */
+    public function getComparisonFailure()
+    {
+        return $this->comparisonFailure;
+    }
+}