lithium\test\Unit::assertNotInternalType()
Assert that $actual is not of given type.
$this->assertNotInternalType('integer', 'foobar'); // succeeds
$this->assertNotInternalType('string', 'foobar'); // fails
Parameters
-
string
$expectedInternal type.
-
object
$actualObject you are testing.
-
string|boolean
$message
Returns
booleantrue if the assertion succeeded, false otherwise.
Source
public function assertNotInternalType($expected, $actual, $message = '{:message}') {
$method = static::$_internalTypes[$expected];
return $this->assert(!$method($actual), $message, [
'expected' => $expected,
'result' => gettype($actual)
]);
}