You are here

public static function PHPUnit_Framework_Assert::assertInternalType in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/phpunit/phpunit/src/Framework/Assert.php \PHPUnit_Framework_Assert::assertInternalType()

Asserts that a variable is of a given type.

@since Method available since Release 3.5.0

Parameters

string $expected:

mixed $actual:

string $message:

18 calls to PHPUnit_Framework_Assert::assertInternalType()
ConsoleTest::testCanDetectColorSupport in vendor/sebastian/environment/tests/ConsoleTest.php
@covers \SebastianBergmann\Environment\Console::hasColorSupport @uses \SebastianBergmann\Environment\Console::isInteractive
ConsoleTest::testCanDetectIfFileDescriptorIsInteractive in vendor/sebastian/environment/tests/ConsoleTest.php
@covers \SebastianBergmann\Environment\Console::isInteractive
ConsoleTest::testCanDetectIfStdoutIsInteractiveByDefault in vendor/sebastian/environment/tests/ConsoleTest.php
@covers \SebastianBergmann\Environment\Console::isInteractive
ConsoleTest::testCanDetectNumberOfColumns in vendor/sebastian/environment/tests/ConsoleTest.php
@covers \SebastianBergmann\Environment\Console::getNumberOfColumns @uses \SebastianBergmann\Environment\Console::isInteractive
Framework_AssertTest::testAssertInternalType in vendor/phpunit/phpunit/tests/Framework/AssertTest.php
@covers PHPUnit_Framework_Assert::assertInternalType

... See full list

File

vendor/phpunit/phpunit/src/Framework/Assert.php, line 1322

Class

PHPUnit_Framework_Assert
A set of assert methods.

Code

public static function assertInternalType($expected, $actual, $message = '') {
  if (!is_string($expected)) {
    throw PHPUnit_Util_InvalidArgumentHelper::factory(1, 'string');
  }
  $constraint = new PHPUnit_Framework_Constraint_IsType($expected);
  self::assertThat($actual, $constraint, $message);
}