public static function PHPUnit_Framework_Assert::assertNotInstanceOf in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/phpunit/phpunit/src/Framework/Assert.php \PHPUnit_Framework_Assert::assertNotInstanceOf()
Asserts that a variable is not of a given type.
@since Method available since Release 3.5.0
Parameters
string $expected:
mixed $actual:
string $message:
3 calls to PHPUnit_Framework_Assert::assertNotInstanceOf()
- Framework_AssertTest::testAssertNotInstanceOf in vendor/
phpunit/ phpunit/ tests/ Framework/ AssertTest.php - @covers PHPUnit_Framework_Assert::assertNotInstanceOf
- Framework_AssertTest::testAssertNotInstanceOfThrowsExceptionForInvalidArgument in vendor/
phpunit/ phpunit/ tests/ Framework/ AssertTest.php - @covers PHPUnit_Framework_Assert::assertNotInstanceOf @expectedException PHPUnit_Framework_Exception
- PHPUnit_Framework_Assert::assertAttributeNotInstanceOf in vendor/
phpunit/ phpunit/ src/ Framework/ Assert.php - Asserts that an attribute is of a given type.
File
- vendor/
phpunit/ phpunit/ src/ Framework/ Assert.php, line 1283
Class
- PHPUnit_Framework_Assert
- A set of assert methods.
Code
public static function assertNotInstanceOf($expected, $actual, $message = '') {
if (!(is_string($expected) && (class_exists($expected) || interface_exists($expected)))) {
throw PHPUnit_Util_InvalidArgumentHelper::factory(1, 'class or interface name');
}
$constraint = new PHPUnit_Framework_Constraint_Not(new PHPUnit_Framework_Constraint_IsInstanceOf($expected));
self::assertThat($actual, $constraint, $message);
}