Test/PHPUnit/Constraint/Redirect34.php
Zend Framework
LICENSE
This source file is subject to the new BSD license that is bundled
with this package in the file LICENSE.txt.
It is also available through the world-wide-web at this URL:
http://framework.zend.com/license/new-bsd
If you did not receive a copy of the license and are unable to
obtain it through the world-wide-web, please send an email
to license@zend.com so we can send you a copy immediately.
- Category
- Zend
- Copyright
- Copyright (c) 2005-2014 Zend Technologies USA Inc. (http://www.zend.com)
- License
- New BSD License
- Package
- Zend_Test
- Subpackage
- PHPUnit
- Version
- $Id$
\Zend_Test_PHPUnit_Constraint_Redirect
Package: Zend_Test\PHPUnit






Redirection constraints
- Parent(s)
- \PHPUnit_Framework_Constraint
- Category
- Zend
- Copyright
- Copyright (c) 2005-2014 Zend Technologies USA Inc. (http://www.zend.com)
- License
- New BSD License
- Uses
Constants
Properties

array $_assertTypes = array(self::ASSERT_REDIRECT, self::ASSERT_REDIRECT_TO, self::ASSERT_REDIRECT_REGEX)Available assertion types
Default value
array(self::ASSERT_REDIRECT, self::ASSERT_REDIRECT_TO, self::ASSERT_REDIRECT_REGEX)Details- Type
- array
Methods

_match(\Zend_Controller_Response_HttpTestCase $response, string $match) : boolCheck to see if content is matched in selected nodes
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $response | \Zend_Controller_Response_HttpTestCase | |
| $match | string | Content to match |
| Type | Description |
|---|---|
| bool |

_notMatch(\Zend_Controller_Response_HttpTestCase $response, string $match) : boolCheck to see if content is NOT matched in selected nodes
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $response | \Zend_Controller_Response_HttpTestCase | |
| $match | string |
| Type | Description |
|---|---|
| bool |

_notRegex(\Zend_Controller_Response_HttpTestCase $response, string $pattern) : boolCheck to see if content is NOT matched by regex in selected nodes
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $response | \Zend_Controller_Response_HttpTestCase | |
| $pattern | string |
| Type | Description |
|---|---|
| bool |

_regex(\Zend_Controller_Response_HttpTestCase $response, string $pattern) : boolCheck to see if content is matched by regex in selected nodes
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $response | \Zend_Controller_Response_HttpTestCase | |
| $pattern | string |
| Type | Description |
|---|---|
| bool |

evaluate(string $other, $assertType = null) : boolEvaluate an object to see if it fits the constraints
Parameters
Returns
| Name | Type | Description |
|---|---|---|
| $other | string | String to examine |
| $assertType |
| Type | Description |
|---|---|
| bool |

fail(mixed $other, string $description, bool $not = false) : voidReport Failure
Parameters
Throws
Details
| Name | Type | Description |
|---|---|---|
| $other | mixed | |
| $description | string | Additional message to display |
| $not | bool |
| Exception | Description |
|---|---|
| \PHPUnit_Framework_ExpectationFailedException |