PHPUnit_Framework_Assert::assertAttributeNotCount PHP Method

assertAttributeNotCount() public static method

Asserts the number of elements of an array, Countable or Traversable that is stored in an attribute.
public static assertAttributeNotCount ( integer $expectedCount, string $haystackAttributeName, string | object $haystackClassOrObject, string $message = '' )
$expectedCount integer
$haystackAttributeName string
$haystackClassOrObject string | object
$message string
    public static function assertAttributeNotCount($expectedCount, $haystackAttributeName, $haystackClassOrObject, $message = '')
    {
        static::assertNotCount($expectedCount, static::readAttribute($haystackClassOrObject, $haystackAttributeName), $message);
    }

Usage Example

Example #1
0
/**
 * Asserts the number of elements of an array, Countable or Iterator
 * that is stored in an attribute.
 *
 * @param integer $expectedCount
 * @param string  $haystackAttributeName
 * @param mixed   $haystackClassOrObject
 * @param string  $message
 * @since Method available since Release 3.6.0
 */
function assertAttributeNotCount($expectedCount, $haystackAttributeName, $haystackClassOrObject, $message = '')
{
    return PHPUnit_Framework_Assert::assertAttributeNotCount($expectedCount, $haystackAttributeName, $haystackClassOrObject, $message);
}
PHPUnit_Framework_Assert