lithium\test\Unit::assertNotCount()
Assert that the passed result array has not the expected number of elements.
$this->assertNotCount(2, ['foo', 'bar', 'bar']); // succeeds
$this->assertNotCount(1, ['foo']); // fails
Parameters
-
integer
$expected
-
array
$array
-
string|boolean
$message
Returns
booleantrue
if the assertion succeeded, false
otherwise.
Source
public function assertNotCount($expected, $array, $message = '{:message}') {
return $this->assert($expected !== ($result = count($array)), $message, [
'expected' => $expected,
'result' => $result
]);
}