Menu

## ShipmentTest extends TestCase
in package

ShipmentTest.php : 19

### Table of Contents

LOCALE_CATEGORIES = [LC_ALL, LC_COLLATE, LC_CTYPE, LC_MONETARY, LC_NUMERIC, LC_TIME]
$backupGlobals : bool|null
$backupGlobalsBlacklist : array<string|int, string>
$backupGlobalsExcludeList : array<string|int, string>
$backupStaticAttributes : bool
$backupStaticAttributesBlacklist : array<string, array<int, string>>
$backupStaticAttributesExcludeList : array<string, array<int, string>>
$preserveGlobalState : bool
$providedTests : list<string|int, ExecutionOrderDependency>
$runTestInSeparateProcess : bool
$beStrictAboutChangesToGlobalState : bool
$count : int
$customComparators : array<string|int, Comparator>
$data : array<string|int, mixed>
$dataName : int|string
$dependencies : list<string|int, ExecutionOrderDependency>
$dependencyInput : array<string|int, mixed>
$doesNotPerformAssertions : bool
$doubledTypes : array<string|int, string>
$expectedException : null|string
$expectedExceptionCode : null|int|string
$expectedExceptionMessage : null|string
$expectedExceptionMessageRegExp : null|string
$groups : array<string|int, string>
$iniSettings : array<string, string>
$inIsolation : bool
$locale : array<string|int, mixed>
$mockObjectGenerator : Generator
$mockObjects : array<string|int, MockObject>
$name : string
$numAssertions : int
$output : string
$outputBufferingActive : bool
$outputBufferingLevel : int
$outputCallback : mixed
$outputExpectedRegex : string|null
$outputExpectedString : string|null
$outputRetrievedForAssertion : bool
$prophet : Prophet
$registerMockObjectsFromTestArgumentsRecursively : bool
$result : TestResult
$runClassInSeparateProcess : bool
$snapshot : Snapshot|null
$status : int
$statusMessage : string
$testResult : mixed
$warnings : array<string|int, string>
any() : AnyInvokedCount
  Returns a matcher that matches when the method is executed zero or more times.
anything() : IsAnything
arrayHasKey() : ArrayHasKey
assertArrayHasKey() : void
  Asserts that an array has a specified key.
assertArrayNotHasKey() : void
  Asserts that an array does not have a specified key.
assertClassHasAttribute() : void
  Asserts that a class has a specified attribute.
assertClassHasStaticAttribute() : void
  Asserts that a class has a specified static attribute.
assertClassNotHasAttribute() : void
  Asserts that a class does not have a specified attribute.
assertClassNotHasStaticAttribute() : void
  Asserts that a class does not have a specified static attribute.
assertContains() : void
  Asserts that a haystack contains a needle.
assertContainsEquals() : void
assertContainsOnly() : void
  Asserts that a haystack contains only values of a given type.
assertContainsOnlyInstancesOf() : void
  Asserts that a haystack contains only instances of a given class name.
assertCount() : void
  Asserts the number of elements of an array, Countable or Traversable.
assertDirectoryDoesNotExist() : void
  Asserts that a directory does not exist.
assertDirectoryExists() : void
  Asserts that a directory exists.
assertDirectoryIsNotReadable() : void
  Asserts that a directory exists and is not readable.
assertDirectoryIsNotWritable() : void
  Asserts that a directory exists and is not writable.
assertDirectoryIsReadable() : void
  Asserts that a directory exists and is readable.
assertDirectoryIsWritable() : void
  Asserts that a directory exists and is writable.
assertDirectoryNotExists() : void
  Asserts that a directory does not exist.
assertDirectoryNotIsReadable() : void
  Asserts that a directory exists and is not readable.
assertDirectoryNotIsWritable() : void
  Asserts that a directory exists and is not writable.
assertDoesNotMatchRegularExpression() : void
  Asserts that a string does not match a given regular expression.
assertEmpty() : void
  Asserts that a variable is empty.
assertEquals() : void
  Asserts that two variables are equal.
assertEqualsCanonicalizing() : void
  Asserts that two variables are equal (canonicalizing).
assertEqualsIgnoringCase() : void
  Asserts that two variables are equal (ignoring case).
assertEqualsWithDelta() : void
  Asserts that two variables are equal (with delta).
assertEqualXMLStructure() : void
  Asserts that a hierarchy of DOMElements matches.
assertFalse() : void
  Asserts that a condition is false.
assertFileDoesNotExist() : void
  Asserts that a file does not exist.
assertFileEquals() : void
  Asserts that the contents of one file is equal to the contents of another file.
assertFileEqualsCanonicalizing() : void
  Asserts that the contents of one file is equal to the contents of another file (canonicalizing).
assertFileEqualsIgnoringCase() : void
  Asserts that the contents of one file is equal to the contents of another file (ignoring case).
assertFileExists() : void
  Asserts that a file exists.
assertFileIsNotReadable() : void
  Asserts that a file exists and is not readable.
assertFileIsNotWritable() : void
  Asserts that a file exists and is not writable.
assertFileIsReadable() : void
  Asserts that a file exists and is readable.
assertFileIsWritable() : void
  Asserts that a file exists and is writable.
assertFileNotEquals() : void
  Asserts that the contents of one file is not equal to the contents of another file.
assertFileNotEqualsCanonicalizing() : void
  Asserts that the contents of one file is not equal to the contents of another file (canonicalizing).
assertFileNotEqualsIgnoringCase() : void
  Asserts that the contents of one file is not equal to the contents of another file (ignoring case).
assertFileNotExists() : void
  Asserts that a file does not exist.
assertFileNotIsReadable() : void
  Asserts that a file exists and is not readable.
assertFileNotIsWritable() : void
  Asserts that a file exists and is not writable.
assertFinite() : void
  Asserts that a variable is finite.
assertGreaterThan() : void
  Asserts that a value is greater than another value.
assertGreaterThanOrEqual() : void
  Asserts that a value is greater than or equal to another value.
assertInfinite() : void
  Asserts that a variable is infinite.
assertInstanceOf() : void
  Asserts that a variable is of a given type.
assertIsArray() : void
  Asserts that a variable is of type array.
assertIsBool() : void
  Asserts that a variable is of type bool.
assertIsCallable() : void
  Asserts that a variable is of type callable.
assertIsClosedResource() : void
  Asserts that a variable is of type resource and is closed.
assertIsFloat() : void
  Asserts that a variable is of type float.
assertIsInt() : void
  Asserts that a variable is of type int.
assertIsIterable() : void
  Asserts that a variable is of type iterable.
assertIsNotArray() : void
  Asserts that a variable is not of type array.
assertIsNotBool() : void
  Asserts that a variable is not of type bool.
assertIsNotCallable() : void
  Asserts that a variable is not of type callable.
assertIsNotClosedResource() : void
  Asserts that a variable is not of type resource.
assertIsNotFloat() : void
  Asserts that a variable is not of type float.
assertIsNotInt() : void
  Asserts that a variable is not of type int.
assertIsNotIterable() : void
  Asserts that a variable is not of type iterable.
assertIsNotNumeric() : void
  Asserts that a variable is not of type numeric.
assertIsNotObject() : void
  Asserts that a variable is not of type object.
assertIsNotReadable() : void
  Asserts that a file/dir exists and is not readable.
assertIsNotResource() : void
  Asserts that a variable is not of type resource.
assertIsNotScalar() : void
  Asserts that a variable is not of type scalar.
assertIsNotString() : void
  Asserts that a variable is not of type string.
assertIsNotWritable() : void
  Asserts that a file/dir exists and is not writable.
assertIsNumeric() : void
  Asserts that a variable is of type numeric.
assertIsObject() : void
  Asserts that a variable is of type object.
assertIsReadable() : void
  Asserts that a file/dir is readable.
assertIsResource() : void
  Asserts that a variable is of type resource.
assertIsScalar() : void
  Asserts that a variable is of type scalar.
assertIsString() : void
  Asserts that a variable is of type string.
assertIsWritable() : void
  Asserts that a file/dir exists and is writable.
assertJson() : void
  Asserts that a string is a valid JSON string.
assertJsonFileEqualsJsonFile() : void
  Asserts that two JSON files are equal.
assertJsonFileNotEqualsJsonFile() : void
  Asserts that two JSON files are not equal.
assertJsonStringEqualsJsonFile() : void
  Asserts that the generated JSON encoded object and the content of the given file are equal.
assertJsonStringEqualsJsonString() : void
  Asserts that two given JSON encoded objects or arrays are equal.
assertJsonStringNotEqualsJsonFile() : void
  Asserts that the generated JSON encoded object and the content of the given file are not equal.
assertJsonStringNotEqualsJsonString() : void
  Asserts that two given JSON encoded objects or arrays are not equal.
assertLessThan() : void
  Asserts that a value is smaller than another value.
assertLessThanOrEqual() : void
  Asserts that a value is smaller than or equal to another value.
assertMatchesRegularExpression() : void
  Asserts that a string matches a given regular expression.
assertNan() : void
  Asserts that a variable is nan.
assertNotContains() : void
  Asserts that a haystack does not contain a needle.
assertNotContainsEquals() : void
assertNotContainsOnly() : void
  Asserts that a haystack does not contain only values of a given type.
assertNotCount() : void
  Asserts the number of elements of an array, Countable or Traversable.
assertNotEmpty() : void
  Asserts that a variable is not empty.
assertNotEquals() : void
  Asserts that two variables are not equal.
assertNotEqualsCanonicalizing() : void
  Asserts that two variables are not equal (canonicalizing).
assertNotEqualsIgnoringCase() : void
  Asserts that two variables are not equal (ignoring case).
assertNotEqualsWithDelta() : void
  Asserts that two variables are not equal (with delta).
assertNotFalse() : void
  Asserts that a condition is not false.
assertNotInstanceOf() : void
  Asserts that a variable is not of a given type.
assertNotIsReadable() : void
  Asserts that a file/dir exists and is not readable.
assertNotIsWritable() : void
  Asserts that a file/dir exists and is not writable.
assertNotNull() : void
  Asserts that a variable is not null.
assertNotRegExp() : void
  Asserts that a string does not match a given regular expression.
assertNotSame() : void
  Asserts that two variables do not have the same type and value.
assertNotSameSize() : void
  Assert that the size of two arrays (or `Countable` or `Traversable` objects) is not the same.
assertNotTrue() : void
  Asserts that a condition is not true.
assertNull() : void
  Asserts that a variable is null.
assertObjectEquals() : void
assertObjectHasAttribute() : void
  Asserts that an object has a specified attribute.
assertObjectNotHasAttribute() : void
  Asserts that an object does not have a specified attribute.
assertRegExp() : void
  Asserts that a string matches a given regular expression.
assertSame() : void
  Asserts that two variables have the same type and value.
assertSameSize() : void
  Assert that the size of two arrays (or `Countable` or `Traversable` objects) is the same.
assertStringContainsString() : void
assertStringContainsStringIgnoringCase() : void
assertStringEndsNotWith() : void
  Asserts that a string ends not with a given suffix.
assertStringEndsWith() : void
  Asserts that a string ends with a given suffix.
assertStringEqualsFile() : void
  Asserts that the contents of a string is equal to the contents of a file.
assertStringEqualsFileCanonicalizing() : void
  Asserts that the contents of a string is equal to the contents of a file (canonicalizing).
assertStringEqualsFileIgnoringCase() : void
  Asserts that the contents of a string is equal to the contents of a file (ignoring case).
assertStringMatchesFormat() : void
  Asserts that a string matches a given format string.
assertStringMatchesFormatFile() : void
  Asserts that a string matches a given format file.
assertStringNotContainsString() : void
assertStringNotContainsStringIgnoringCase() : void
assertStringNotEqualsFile() : void
  Asserts that the contents of a string is not equal to the contents of a file.
assertStringNotEqualsFileCanonicalizing() : void
  Asserts that the contents of a string is not equal to the contents of a file (canonicalizing).
assertStringNotEqualsFileIgnoringCase() : void
  Asserts that the contents of a string is not equal to the contents of a file (ignoring case).
assertStringNotMatchesFormat() : void
  Asserts that a string does not match a given format string.
assertStringNotMatchesFormatFile() : void
  Asserts that a string does not match a given format string.
assertStringStartsNotWith() : void
  Asserts that a string starts not with a given prefix.
assertStringStartsWith() : void
  Asserts that a string starts with a given prefix.
assertThat() : void
  Evaluates a PHPUnit\Framework\Constraint matcher object.
assertTrue() : void
  Asserts that a condition is true.
assertXmlFileEqualsXmlFile() : void
  Asserts that two XML files are equal.
assertXmlFileNotEqualsXmlFile() : void
  Asserts that two XML files are not equal.
assertXmlStringEqualsXmlFile() : void
  Asserts that two XML documents are equal.
assertXmlStringEqualsXmlString() : void
  Asserts that two XML documents are equal.
assertXmlStringNotEqualsXmlFile() : void
  Asserts that two XML documents are not equal.
assertXmlStringNotEqualsXmlString() : void
  Asserts that two XML documents are not equal.
at() : InvokedAtIndex
  Returns a matcher that matches when the method is executed at the given index.
atLeast() : InvokedAtLeastCount
  Returns a matcher that matches when the method is executed at least N times.
atLeastOnce() : InvokedAtLeastOnce
  Returns a matcher that matches when the method is executed at least once.
atMost() : InvokedAtMostCount
  Returns a matcher that matches when the method is executed at most N times.
callback() : Callback
classHasAttribute() : ClassHasAttribute
classHasStaticAttribute() : ClassHasStaticAttribute
containsEqual() : TraversableContainsEqual
containsIdentical() : TraversableContainsIdentical
containsOnly() : TraversableContainsOnly
containsOnlyInstancesOf() : TraversableContainsOnly
count() : int
countOf() : Count
directoryExists() : DirectoryExists
equalTo() : IsEqual
equalToCanonicalizing() : IsEqualCanonicalizing
equalToIgnoringCase() : IsEqualIgnoringCase
equalToWithDelta() : IsEqualWithDelta
exactly() : InvokedCount
  Returns a matcher that matches when the method is executed exactly $count times.
expectDeprecation() : void
expectDeprecationMessage() : void
expectDeprecationMessageMatches() : void
expectError() : void
expectErrorMessage() : void
expectErrorMessageMatches() : void
expectException() : void
expectExceptionCode() : void
expectExceptionMessage() : void
expectExceptionMessageMatches() : void
expectExceptionObject() : void
  Sets up an expectation for an exception to be raised by the code under test.
expectNotice() : void
expectNoticeMessage() : void
expectNoticeMessageMatches() : void
expectNotToPerformAssertions() : void
expectOutputRegex() : void
expectOutputString() : void
expectWarning() : void
expectWarningMessage() : void
expectWarningMessageMatches() : void
fail() : void
  Fails a test with the given message.
fileExists() : FileExists
getActualOutputForAssertion() : string
getCount() : int
  Return the current assertion count.
getMockBuilder() : MockBuilder
  Returns a builder object to create mock objects using a fluent interface.
getStatus() : int
getStatusMessage() : string
greaterThan() : GreaterThan
greaterThanOrEqual() : LogicalOr
hasFailed() : bool
identicalTo() : IsIdentical
isEmpty() : IsEmpty
isFalse() : IsFalse
isFinite() : IsFinite
isInfinite() : IsInfinite
isInstanceOf() : IsInstanceOf
isJson() : IsJson
isNan() : IsNan
isNull() : IsNull
isReadable() : IsReadable
isTrue() : IsTrue
isType() : IsType
isWritable() : IsWritable
lessThan() : LessThan
lessThanOrEqual() : LogicalOr
logicalAnd() : LogicalAnd
logicalNot() : LogicalNot
logicalOr() : LogicalOr
logicalXor() : LogicalXor
markAsRisky() : void
markTestIncomplete() : void
  Mark the test as incomplete.
markTestSkipped() : void
  Mark the test as skipped.
matches() : StringMatchesFormatDescription
matchesRegularExpression() : RegularExpression
never() : InvokedCount
  Returns a matcher that matches when the method is never executed.
objectEquals() : ObjectEquals
objectHasAttribute() : ObjectHasAttribute
once() : InvokedCount
  Returns a matcher that matches when the method is executed exactly once.
onConsecutiveCalls() : ConsecutiveCalls
provides() : list<string|int, ExecutionOrderDependency>
  Returns the normalized test name as class::method.
registerComparator() : void
requires() : list<string|int, ExecutionOrderDependency>
  Returns a list of normalized dependency names, class::method.
resetCount() : void
  Reset the assertion counter.
returnArgument() : ReturnArgument
returnCallback() : ReturnCallback
returnSelf() : ReturnSelf
  Returns the current object.
returnValue() : ReturnStub
returnValueMap() : ReturnValueMap
run() : TestResult
  Runs the test case and collects the results in a TestResult object.
setUpBeforeClass() : void
  This method is called before the first test of this test class is run.
sortId() : string
stringContains() : StringContains
stringEndsWith() : StringEndsWith
stringStartsWith() : StringStartsWith
tearDownAfterClass() : void
  This method is called after the last test of this test class is run.
test_create_instance_with_invalid_arguments() : void
test_create_instance_with_invalid_carrier_argument() : void
test_create_instance_without_arguments() : void
test_create_valid_instance() : void
test_create_valid_instance_and_set_invalid_carrier() : void
test_create_valid_instance_and_set_invalid_incoterm() : void
test_create_valid_instance_and_set_invalid_service() : void
test_to_array() : void
throwException() : Exception
toString() : string
  Returns a string representation of the test case.
assertPostConditions() : void
  Performs assertions shared by all tests of a test case.
assertPreConditions() : void
  Performs assertions shared by all tests of a test case.
createConfiguredMock() : MockObject
  Returns a configured mock object for the specified class.
createMock() : MockObject
  Returns a mock object for the specified class.
createPartialMock() : MockObject
  Returns a partial mock object for the specified class.
createStub() : Stub
  Makes configurable stub for the specified class.
createTestProxy() : MockObject
  Returns a test proxy for the specified class.
getMockClass() : string
  Mocks the specified class and returns the name of the mocked class.
getMockForAbstractClass() : MockObject
  Returns a mock object for the specified abstract class with all abstract methods of the class mocked. Concrete methods are not mocked by default.
getMockForTrait() : MockObject
  Returns a mock object for the specified trait with all abstract methods of the trait mocked. Concrete methods to mock can be specified with the `$mockedMethods` parameter.
getMockFromWsdl() : MockObject
  Returns a mock object based on the given WSDL file.
getObjectForTrait() : object
  Returns an object for the specified trait.
iniSet() : void
  This method is a wrapper for the ini_set() function that automatically resets the modified php.ini setting to its original value after the test is run.
onNotSuccessfulTest() : void
  This method is called when a test method did not execute successfully.
prophesize() : ObjectProphecy
recordDoubledType() : void
runTest() : mixed
  Override to run the test and assert its state.
setLocale() : void
  This method is a wrapper for the setlocale() function that automatically resets the locale to its original value after the test is run.
setUp() : void
  This method is called before each test.
tearDown() : void
  This method is called after each test.
checkExceptionExpectations() : bool
checkRequirements() : void
cleanupIniSettings() : void
cleanupLocaleSettings() : void
compareGlobalStateSnapshotPart() : void
compareGlobalStateSnapshots() : void
createGlobalStateSnapshot() : Snapshot
createMockObject() : MockObject
createWarning() : void
detectLocationHint() : array<string|int, mixed>|null
get_valid_instance() : mixed
getMockObjectGenerator() : Generator
  Get the mock object generator, creating it if it doesn't exist.
getProphet() : Prophet
handleDependencies() : bool
isCallableTestMethod() : bool
isValidClassAttributeName() : bool
isValidObjectAttributeName() : bool
markSkippedForMissingDependency() : void
markSkippedForNotSpecifyingDependency() : void
markWarningForUncallableDependency() : void
registerMockObjectsFromTestArguments() : void
restoreGlobalState() : void
runInSeparateProcess() : bool
setDoesNotPerformAssertionsFromAnnotation() : void
shouldInvocationMockerBeReset() : bool
snapshotGlobalState() : void
startOutputBuffering() : void
stopOutputBuffering() : void
unregisterCustomComparators() : void
verifyMockObjects() : void

### Constants

#### LOCALE_CATEGORIES

TestCase.php : 122
`private mixed LOCALE_CATEGORIES = [LC_ALL, LC_COLLATE, LC_CTYPE, LC_MONETARY, LC_NUMERIC, LC_TIME]`

### Properties

#### $backupGlobals

TestCase.php : 127
`protected bool|null $backupGlobals`

#### $backupGlobalsBlacklist

TestCase.php : 139
`protected array<string|int, string> $backupGlobalsBlacklist = []`

##### Tags

deprecated

  Use $backupGlobalsExcludeList instead

#### $backupGlobalsExcludeList

TestCase.php : 132
`protected array<string|int, string> $backupGlobalsExcludeList = []`

#### $backupStaticAttributes

TestCase.php : 144
`protected bool $backupStaticAttributes`

#### $backupStaticAttributesBlacklist

TestCase.php : 156
`protected array<string, array<int, string>> $backupStaticAttributesBlacklist = []`

##### Tags

deprecated

  Use $backupStaticAttributesExcludeList instead

#### $backupStaticAttributesExcludeList

TestCase.php : 149
`protected array<string, array<int, string>> $backupStaticAttributesExcludeList = []`

#### $preserveGlobalState

TestCase.php : 166
`protected bool $preserveGlobalState = true`

#### $providedTests

TestCase.php : 171
`protected list<string|int, ExecutionOrderDependency> $providedTests = []`

#### $runTestInSeparateProcess

TestCase.php : 161
`protected bool $runTestInSeparateProcess`

#### $beStrictAboutChangesToGlobalState

TestCase.php : 321
`private bool $beStrictAboutChangesToGlobalState = false`

#### $count

Assert.php : 96
`private static int $count = 0`

#### $customComparators

TestCase.php : 346
`private array<string|int, Comparator> $customComparators = []`

#### $data

TestCase.php : 186
`private array<string|int, mixed> $data`

#### $dataName

TestCase.php : 191
`private int|string $dataName`

#### $dependencies

TestCase.php : 221
`private list<string|int, ExecutionOrderDependency> $dependencies = []`

#### $dependencyInput

TestCase.php : 226
`private array<string|int, mixed> $dependencyInput = []`

#### $doesNotPerformAssertions

TestCase.php : 341
`private bool $doesNotPerformAssertions = false`

#### $doubledTypes

TestCase.php : 351
`private array<string|int, string> $doubledTypes = []`

#### $expectedException

TestCase.php : 196
`private null|string $expectedException`

#### $expectedExceptionCode

TestCase.php : 211
`private null|int|string $expectedExceptionCode`

#### $expectedExceptionMessage

TestCase.php : 201
`private null|string $expectedExceptionMessage`

#### $expectedExceptionMessageRegExp

TestCase.php : 206
`private null|string $expectedExceptionMessageRegExp`

#### $groups

TestCase.php : 336
`private array<string|int, string> $groups = []`

#### $iniSettings

TestCase.php : 231
`private array<string, string> $iniSettings = []`

#### $inIsolation

TestCase.php : 181
`private bool $inIsolation = false`

#### $locale

TestCase.php : 236
`private array<string|int, mixed> $locale = []`

#### $mockObjectGenerator

TestCase.php : 246
`private Generator $mockObjectGenerator`

#### $mockObjects

TestCase.php : 241
`private array<string|int, MockObject> $mockObjects = []`

#### $name

TestCase.php : 216
`private string $name = ''`

#### $numAssertions

TestCase.php : 261
`private int $numAssertions = 0`

#### $output

TestCase.php : 276
`private string $output = ''`

#### $outputBufferingActive

TestCase.php : 296
`private bool $outputBufferingActive = false`

#### $outputBufferingLevel

TestCase.php : 301
`private int $outputBufferingLevel`

#### $outputCallback

TestCase.php : 291
`private mixed $outputCallback = false`

#### $outputExpectedRegex

TestCase.php : 281
`private string|null $outputExpectedRegex`

#### $outputExpectedString

TestCase.php : 286
`private string|null $outputExpectedString`

#### $outputRetrievedForAssertion

TestCase.php : 306
`private bool $outputRetrievedForAssertion = false`

#### $prophet

TestCase.php : 316
`private Prophet $prophet`

#### $registerMockObjectsFromTestArgumentsRecursively

TestCase.php : 326
`private bool $registerMockObjectsFromTestArgumentsRecursively = false`

#### $result

TestCase.php : 266
`private TestResult $result`

#### $runClassInSeparateProcess

TestCase.php : 176
`private bool $runClassInSeparateProcess`

#### $snapshot

TestCase.php : 311
`private Snapshot|null $snapshot`

#### $status

TestCase.php : 251
`private int $status = PHPUnitRunnerBaseTestRunner::STATUS_UNKNOWN`

#### $statusMessage

TestCase.php : 256
`private string $statusMessage = ''`

#### $testResult

TestCase.php : 271
`private mixed $testResult`

#### $warnings

TestCase.php : 331
`private array<string|int, string> $warnings = []`

### Methods

#### any()

TestCase.php : 357

Returns a matcher that matches when the method is executed zero or more times.

`public static any() : AnyInvokedCount`

##### Return values

AnyInvokedCount —

#### anything()

Assert.php : 2527
`public static anything() : IsAnything`

##### Return values

IsAnything —

#### arrayHasKey()

Assert.php : 2602
`public static arrayHasKey(int|string $key) : ArrayHasKey`

##### Parameters

$key : int|string

##### Return values

ArrayHasKey —

#### assertArrayHasKey()

Assert.php : 108

Asserts that an array has a specified key.

`public static assertArrayHasKey(int|string $key, array<string|int, mixed>|ArrayAccess $array[, string $message = '' ]) : void`

##### Parameters

$key : int|string
$array : array<string|int, mixed>|ArrayAccess
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException

##### Return values

void —

#### assertArrayNotHasKey()

Assert.php : 139

Asserts that an array does not have a specified key.

`public static assertArrayNotHasKey(int|string $key, array<string|int, mixed>|ArrayAccess $array[, string $message = '' ]) : void`

##### Parameters

$key : int|string
$array : array<string|int, mixed>|ArrayAccess
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException

##### Return values

void —

#### assertClassHasAttribute()

Assert.php : 1172

Asserts that a class has a specified attribute.

`public static assertClassHasAttribute(string $attributeName, string $className[, string $message = '' ]) : void`

##### Parameters

$attributeName : string
$className : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException

##### Return values

void —

#### assertClassHasStaticAttribute()

Assert.php : 1218

Asserts that a class has a specified static attribute.

`public static assertClassHasStaticAttribute(string $attributeName, string $className[, string $message = '' ]) : void`

##### Parameters

$attributeName : string
$className : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException

##### Return values

void —

#### assertClassNotHasAttribute()

Assert.php : 1192

Asserts that a class does not have a specified attribute.

`public static assertClassNotHasAttribute(string $attributeName, string $className[, string $message = '' ]) : void`

##### Parameters

$attributeName : string
$className : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException

##### Return values

void —

#### assertClassNotHasStaticAttribute()

Assert.php : 1242

Asserts that a class does not have a specified static attribute.

`public static assertClassNotHasStaticAttribute(string $attributeName, string $className[, string $message = '' ]) : void`

##### Parameters

$attributeName : string
$className : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException

##### Return values

void —

#### assertContains()

Assert.php : 169

Asserts that a haystack contains a needle.

`public static assertContains(mixed $needle, iteratable<string|int, mixed> $haystack[, string $message = '' ]) : void`

##### Parameters

$needle : mixed
$haystack : iteratable<string|int, mixed>
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException

##### Return values

void —

#### assertContainsEquals()

Assert.php : 176
`public static assertContainsEquals(mixed $needle, iteratable<string|int, mixed> $haystack[, string $message = '' ]) : void`

##### Parameters

$needle : mixed
$haystack : iteratable<string|int, mixed>
$message : string = ''

##### Return values

void —

#### assertContainsOnly()

Assert.php : 212

Asserts that a haystack contains only values of a given type.

`public static assertContainsOnly(string $type, iteratable<string|int, mixed> $haystack[, bool|null $isNativeType = null ][, string $message = '' ]) : void`

##### Parameters

$type : string
$haystack : iteratable<string|int, mixed>
$isNativeType : bool|null = null
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertContainsOnlyInstancesOf()

Assert.php : 234

Asserts that a haystack contains only instances of a given class name.

`public static assertContainsOnlyInstancesOf(string $className, iteratable<string|int, mixed> $haystack[, string $message = '' ]) : void`

##### Parameters

$className : string
$haystack : iteratable<string|int, mixed>
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertCount()

Assert.php : 279

Asserts the number of elements of an array, Countable or Traversable.

`public static assertCount(int $expectedCount, Countable|iteratable<string|int, mixed> $haystack[, string $message = '' ]) : void`

##### Parameters

$expectedCount : int
$haystack : Countable|iteratable<string|int, mixed>
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException

##### Return values

void —

#### assertDirectoryDoesNotExist()

Assert.php : 825

Asserts that a directory does not exist.

`public static assertDirectoryDoesNotExist(string $directory[, string $message = '' ]) : void`

##### Parameters

$directory : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertDirectoryExists()

Assert.php : 814

Asserts that a directory exists.

`public static assertDirectoryExists(string $directory[, string $message = '' ]) : void`

##### Parameters

$directory : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertDirectoryIsNotReadable()

Assert.php : 865

Asserts that a directory exists and is not readable.

`public static assertDirectoryIsNotReadable(string $directory[, string $message = '' ]) : void`

##### Parameters

$directory : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertDirectoryIsNotWritable()

Assert.php : 907

Asserts that a directory exists and is not writable.

`public static assertDirectoryIsNotWritable(string $directory[, string $message = '' ]) : void`

##### Parameters

$directory : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertDirectoryIsReadable()

Assert.php : 853

Asserts that a directory exists and is readable.

`public static assertDirectoryIsReadable(string $directory[, string $message = '' ]) : void`

##### Parameters

$directory : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertDirectoryIsWritable()

Assert.php : 895

Asserts that a directory exists and is writable.

`public static assertDirectoryIsWritable(string $directory[, string $message = '' ]) : void`

##### Parameters

$directory : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertDirectoryNotExists()

Assert.php : 840

Asserts that a directory does not exist.

`public static assertDirectoryNotExists(string $directory[, string $message = '' ]) : void`

##### Parameters

$directory : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
codeCoverageIgnore
deprecated

  https://github.com/sebastianbergmann/phpunit/issues/4068

##### Return values

void —

#### assertDirectoryNotIsReadable()

Assert.php : 881

Asserts that a directory exists and is not readable.

`public static assertDirectoryNotIsReadable(string $directory[, string $message = '' ]) : void`

##### Parameters

$directory : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
codeCoverageIgnore
deprecated

  https://github.com/sebastianbergmann/phpunit/issues/4071

##### Return values

void —

#### assertDirectoryNotIsWritable()

Assert.php : 923

Asserts that a directory exists and is not writable.

`public static assertDirectoryNotIsWritable(string $directory[, string $message = '' ]) : void`

##### Parameters

$directory : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
codeCoverageIgnore
deprecated

  https://github.com/sebastianbergmann/phpunit/issues/4074

##### Return values

void —

#### assertDoesNotMatchRegularExpression()

Assert.php : 1851

Asserts that a string does not match a given regular expression.

`public static assertDoesNotMatchRegularExpression(string $pattern, string $string[, string $message = '' ]) : void`

##### Parameters

$pattern : string
$string : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertEmpty()

Assert.php : 452

Asserts that a variable is empty.

`public static assertEmpty(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  empty $actual

##### Return values

void —

#### assertEquals()

Assert.php : 320

Asserts that two variables are equal.

`public static assertEquals(mixed $expected, mixed $actual[, string $message = '' ]) : void`

##### Parameters

$expected : mixed
$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertEqualsCanonicalizing()

Assert.php : 333

Asserts that two variables are equal (canonicalizing).

`public static assertEqualsCanonicalizing(mixed $expected, mixed $actual[, string $message = '' ]) : void`

##### Parameters

$expected : mixed
$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertEqualsIgnoringCase()

Assert.php : 346

Asserts that two variables are equal (ignoring case).

`public static assertEqualsIgnoringCase(mixed $expected, mixed $actual[, string $message = '' ]) : void`

##### Parameters

$expected : mixed
$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertEqualsWithDelta()

Assert.php : 359

Asserts that two variables are equal (with delta).

`public static assertEqualsWithDelta(mixed $expected, mixed $actual, float $delta[, string $message = '' ]) : void`

##### Parameters

$expected : mixed
$actual : mixed
$delta : float
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertEqualXMLStructure()

Assert.php : 2265

Asserts that a hierarchy of DOMElements matches.

`public static assertEqualXMLStructure(DOMElement $expectedElement, DOMElement $actualElement[, bool $checkAttributes = false ][, string $message = '' ]) : void`

##### Parameters

$expectedElement : DOMElement
$actualElement : DOMElement
$checkAttributes : bool = false
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  AssertionFailedError
throws
  ExpectationFailedException
codeCoverageIgnore
deprecated

  https://github.com/sebastianbergmann/phpunit/issues/4091

##### Return values

void —

#### assertFalse()

Assert.php : 1088

Asserts that a condition is false.

`public static assertFalse(mixed $condition[, string $message = '' ]) : void`

##### Parameters

$condition : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  false $condition

##### Return values

void —

#### assertFileDoesNotExist()

Assert.php : 948

Asserts that a file does not exist.

`public static assertFileDoesNotExist(string $filename[, string $message = '' ]) : void`

##### Parameters

$filename : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertFileEquals()

Assert.php : 525

Asserts that the contents of one file is equal to the contents of another file.

`public static assertFileEquals(string $expected, string $actual[, string $message = '' ]) : void`

##### Parameters

$expected : string
$actual : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertFileEqualsCanonicalizing()

Assert.php : 542

Asserts that the contents of one file is equal to the contents of another file (canonicalizing).

`public static assertFileEqualsCanonicalizing(string $expected, string $actual[, string $message = '' ]) : void`

##### Parameters

$expected : string
$actual : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertFileEqualsIgnoringCase()

Assert.php : 561

Asserts that the contents of one file is equal to the contents of another file (ignoring case).

`public static assertFileEqualsIgnoringCase(string $expected, string $actual[, string $message = '' ]) : void`

##### Parameters

$expected : string
$actual : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertFileExists()

Assert.php : 937

Asserts that a file exists.

`public static assertFileExists(string $filename[, string $message = '' ]) : void`

##### Parameters

$filename : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertFileIsNotReadable()

Assert.php : 988

Asserts that a file exists and is not readable.

`public static assertFileIsNotReadable(string $file[, string $message = '' ]) : void`

##### Parameters

$file : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertFileIsNotWritable()

Assert.php : 1030

Asserts that a file exists and is not writable.

`public static assertFileIsNotWritable(string $file[, string $message = '' ]) : void`

##### Parameters

$file : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertFileIsReadable()

Assert.php : 976

Asserts that a file exists and is readable.

`public static assertFileIsReadable(string $file[, string $message = '' ]) : void`

##### Parameters

$file : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertFileIsWritable()

Assert.php : 1018

Asserts that a file exists and is writable.

`public static assertFileIsWritable(string $file[, string $message = '' ]) : void`

##### Parameters

$file : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertFileNotEquals()

Assert.php : 578

Asserts that the contents of one file is not equal to the contents of another file.

`public static assertFileNotEquals(string $expected, string $actual[, string $message = '' ]) : void`

##### Parameters

$expected : string
$actual : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertFileNotEqualsCanonicalizing()

Assert.php : 597

Asserts that the contents of one file is not equal to the contents of another file (canonicalizing).

`public static assertFileNotEqualsCanonicalizing(string $expected, string $actual[, string $message = '' ]) : void`

##### Parameters

$expected : string
$actual : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertFileNotEqualsIgnoringCase()

Assert.php : 616

Asserts that the contents of one file is not equal to the contents of another file (ignoring case).

`public static assertFileNotEqualsIgnoringCase(string $expected, string $actual[, string $message = '' ]) : void`

##### Parameters

$expected : string
$actual : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertFileNotExists()

Assert.php : 963

Asserts that a file does not exist.

`public static assertFileNotExists(string $filename[, string $message = '' ]) : void`

##### Parameters

$filename : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
codeCoverageIgnore
deprecated

  https://github.com/sebastianbergmann/phpunit/issues/4077

##### Return values

void —

#### assertFileNotIsReadable()

Assert.php : 1004

Asserts that a file exists and is not readable.

`public static assertFileNotIsReadable(string $file[, string $message = '' ]) : void`

##### Parameters

$file : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
codeCoverageIgnore
deprecated

  https://github.com/sebastianbergmann/phpunit/issues/4080

##### Return values

void —

#### assertFileNotIsWritable()

Assert.php : 1046

Asserts that a file exists and is not writable.

`public static assertFileNotIsWritable(string $file[, string $message = '' ]) : void`

##### Parameters

$file : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
codeCoverageIgnore
deprecated

  https://github.com/sebastianbergmann/phpunit/issues/4083

##### Return values

void —

#### assertFinite()

Assert.php : 1138

Asserts that a variable is finite.

`public static assertFinite(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertGreaterThan()

Assert.php : 476

Asserts that a value is greater than another value.

`public static assertGreaterThan(mixed $expected, mixed $actual[, string $message = '' ]) : void`

##### Parameters

$expected : mixed
$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertGreaterThanOrEqual()

Assert.php : 487

Asserts that a value is greater than or equal to another value.

`public static assertGreaterThanOrEqual(mixed $expected, mixed $actual[, string $message = '' ]) : void`

##### Parameters

$expected : mixed
$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertInfinite()

Assert.php : 1149

Asserts that a variable is infinite.

`public static assertInfinite(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertInstanceOf()

Assert.php : 1370

Asserts that a variable is of a given type.

`public static assertInstanceOf(string $expected, mixed $actual[, string $message = '' ]) : void`

##### Parameters

$expected : string
$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException
psalm-template

  ExpectedType of object

psalm-param

  class-string $expected

psalm-assert

  =ExpectedType $actual

##### Return values

void —

#### assertIsArray()

Assert.php : 1417

Asserts that a variable is of type array.

`public static assertIsArray(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  array $actual

##### Return values

void —

#### assertIsBool()

Assert.php : 1434

Asserts that a variable is of type bool.

`public static assertIsBool(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  bool $actual

##### Return values

void —

#### assertIsCallable()

Assert.php : 1587

Asserts that a variable is of type callable.

`public static assertIsCallable(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  callable $actual

##### Return values

void —

#### assertIsClosedResource()

Assert.php : 1536

Asserts that a variable is of type resource and is closed.

`public static assertIsClosedResource(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  resource $actual

##### Return values

void —

#### assertIsFloat()

Assert.php : 1451

Asserts that a variable is of type float.

`public static assertIsFloat(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  float $actual

##### Return values

void —

#### assertIsInt()

Assert.php : 1468

Asserts that a variable is of type int.

`public static assertIsInt(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  int $actual

##### Return values

void —

#### assertIsIterable()

Assert.php : 1604

Asserts that a variable is of type iterable.

`public static assertIsIterable(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  iterable $actual

##### Return values

void —

#### assertIsNotArray()

Assert.php : 1621

Asserts that a variable is not of type array.

`public static assertIsNotArray(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  !array $actual

##### Return values

void —

#### assertIsNotBool()

Assert.php : 1638

Asserts that a variable is not of type bool.

`public static assertIsNotBool(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  !bool $actual

##### Return values

void —

#### assertIsNotCallable()

Assert.php : 1791

Asserts that a variable is not of type callable.

`public static assertIsNotCallable(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  !callable $actual

##### Return values

void —

#### assertIsNotClosedResource()

Assert.php : 1740

Asserts that a variable is not of type resource.

`public static assertIsNotClosedResource(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  !resource $actual

##### Return values

void —

#### assertIsNotFloat()

Assert.php : 1655

Asserts that a variable is not of type float.

`public static assertIsNotFloat(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  !float $actual

##### Return values

void —

#### assertIsNotInt()

Assert.php : 1672

Asserts that a variable is not of type int.

`public static assertIsNotInt(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  !int $actual

##### Return values

void —

#### assertIsNotIterable()

Assert.php : 1808

Asserts that a variable is not of type iterable.

`public static assertIsNotIterable(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  !iterable $actual

##### Return values

void —

#### assertIsNotNumeric()

Assert.php : 1689

Asserts that a variable is not of type numeric.

`public static assertIsNotNumeric(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  !numeric $actual

##### Return values

void —

#### assertIsNotObject()

Assert.php : 1706

Asserts that a variable is not of type object.

`public static assertIsNotObject(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  !object $actual

##### Return values

void —

#### assertIsNotReadable()

Assert.php : 747

Asserts that a file/dir exists and is not readable.

`public static assertIsNotReadable(string $filename[, string $message = '' ]) : void`

##### Parameters

$filename : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertIsNotResource()

Assert.php : 1723

Asserts that a variable is not of type resource.

`public static assertIsNotResource(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  !resource $actual

##### Return values

void —

#### assertIsNotScalar()

Assert.php : 1774

Asserts that a variable is not of type scalar.

`public static assertIsNotScalar(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  !scalar $actual

##### Return values

void —

#### assertIsNotString()

Assert.php : 1757

Asserts that a variable is not of type string.

`public static assertIsNotString(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  !string $actual

##### Return values

void —

#### assertIsNotWritable()

Assert.php : 786

Asserts that a file/dir exists and is not writable.

`public static assertIsNotWritable(string $filename[, string $message = '' ]) : void`

##### Parameters

$filename : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertIsNumeric()

Assert.php : 1485

Asserts that a variable is of type numeric.

`public static assertIsNumeric(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  numeric $actual

##### Return values

void —

#### assertIsObject()

Assert.php : 1502

Asserts that a variable is of type object.

`public static assertIsObject(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  object $actual

##### Return values

void —

#### assertIsReadable()

Assert.php : 736

Asserts that a file/dir is readable.

`public static assertIsReadable(string $filename[, string $message = '' ]) : void`

##### Parameters

$filename : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertIsResource()

Assert.php : 1519

Asserts that a variable is of type resource.

`public static assertIsResource(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  resource $actual

##### Return values

void —

#### assertIsScalar()

Assert.php : 1570

Asserts that a variable is of type scalar.

`public static assertIsScalar(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  scalar $actual

##### Return values

void —

#### assertIsString()

Assert.php : 1553

Asserts that a variable is of type string.

`public static assertIsString(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  string $actual

##### Return values

void —

#### assertIsWritable()

Assert.php : 775

Asserts that a file/dir exists and is writable.

`public static assertIsWritable(string $filename[, string $message = '' ]) : void`

##### Parameters

$filename : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertJson()

Assert.php : 2353

Asserts that a string is a valid JSON string.

`public static assertJson(string $actualJson[, string $message = '' ]) : void`

##### Parameters

$actualJson : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertJsonFileEqualsJsonFile()

Assert.php : 2441

Asserts that two JSON files are equal.

`public static assertJsonFileEqualsJsonFile(string $expectedFile, string $actualFile[, string $message = '' ]) : void`

##### Parameters

$expectedFile : string
$actualFile : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertJsonFileNotEqualsJsonFile()

Assert.php : 2468

Asserts that two JSON files are not equal.

`public static assertJsonFileNotEqualsJsonFile(string $expectedFile, string $actualFile[, string $message = '' ]) : void`

##### Parameters

$expectedFile : string
$actualFile : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertJsonStringEqualsJsonFile()

Assert.php : 2401

Asserts that the generated JSON encoded object and the content of the given file are equal.

`public static assertJsonStringEqualsJsonFile(string $expectedFile, string $actualJson[, string $message = '' ]) : void`

##### Parameters

$expectedFile : string
$actualJson : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertJsonStringEqualsJsonString()

Assert.php : 2364

Asserts that two given JSON encoded objects or arrays are equal.

`public static assertJsonStringEqualsJsonString(string $expectedJson, string $actualJson[, string $message = '' ]) : void`

##### Parameters

$expectedJson : string
$actualJson : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertJsonStringNotEqualsJsonFile()

Assert.php : 2418

Asserts that the generated JSON encoded object and the content of the given file are not equal.

`public static assertJsonStringNotEqualsJsonFile(string $expectedFile, string $actualJson[, string $message = '' ]) : void`

##### Parameters

$expectedFile : string
$actualJson : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertJsonStringNotEqualsJsonString()

Assert.php : 2381

Asserts that two given JSON encoded objects or arrays are not equal.

`public static assertJsonStringNotEqualsJsonString(string $expectedJson, string $actualJson[, string $message = '' ]) : void`

##### Parameters

$expectedJson : string
$actualJson : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertLessThan()

Assert.php : 502

Asserts that a value is smaller than another value.

`public static assertLessThan(mixed $expected, mixed $actual[, string $message = '' ]) : void`

##### Parameters

$expected : mixed
$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertLessThanOrEqual()

Assert.php : 513

Asserts that a value is smaller than or equal to another value.

`public static assertLessThanOrEqual(mixed $expected, mixed $actual[, string $message = '' ]) : void`

##### Parameters

$expected : mixed
$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertMatchesRegularExpression()

Assert.php : 1823

Asserts that a string matches a given regular expression.

`public static assertMatchesRegularExpression(string $pattern, string $string[, string $message = '' ]) : void`

##### Parameters

$pattern : string
$string : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertNan()

Assert.php : 1160

Asserts that a variable is nan.

`public static assertNan(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertNotContains()

Assert.php : 190

Asserts that a haystack does not contain a needle.

`public static assertNotContains(mixed $needle, iteratable<string|int, mixed> $haystack[, string $message = '' ]) : void`

##### Parameters

$needle : mixed
$haystack : iteratable<string|int, mixed>
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException

##### Return values

void —

#### assertNotContainsEquals()

Assert.php : 199
`public static assertNotContainsEquals(mixed $needle, iteratable<string|int, mixed> $haystack[, string $message = '' ]) : void`

##### Parameters

$needle : mixed
$haystack : iteratable<string|int, mixed>
$message : string = ''

##### Return values

void —

#### assertNotContainsOnly()

Assert.php : 252

Asserts that a haystack does not contain only values of a given type.

`public static assertNotContainsOnly(string $type, iteratable<string|int, mixed> $haystack[, bool|null $isNativeType = null ][, string $message = '' ]) : void`

##### Parameters

$type : string
$haystack : iteratable<string|int, mixed>
$isNativeType : bool|null = null
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertNotCount()

Assert.php : 301

Asserts the number of elements of an array, Countable or Traversable.

`public static assertNotCount(int $expectedCount, Countable|iteratable<string|int, mixed> $haystack[, string $message = '' ]) : void`

##### Parameters

$expectedCount : int
$haystack : Countable|iteratable<string|int, mixed>
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException

##### Return values

void —

#### assertNotEmpty()

Assert.php : 465

Asserts that a variable is not empty.

`public static assertNotEmpty(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  !empty $actual

##### Return values

void —

#### assertNotEquals()

Assert.php : 375

Asserts that two variables are not equal.

`public static assertNotEquals(mixed $expected, mixed $actual[, string $message = '' ]) : void`

##### Parameters

$expected : mixed
$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertNotEqualsCanonicalizing()

Assert.php : 390

Asserts that two variables are not equal (canonicalizing).

`public static assertNotEqualsCanonicalizing(mixed $expected, mixed $actual[, string $message = '' ]) : void`

##### Parameters

$expected : mixed
$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertNotEqualsIgnoringCase()

Assert.php : 405

Asserts that two variables are not equal (ignoring case).

`public static assertNotEqualsIgnoringCase(mixed $expected, mixed $actual[, string $message = '' ]) : void`

##### Parameters

$expected : mixed
$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertNotEqualsWithDelta()

Assert.php : 420

Asserts that two variables are not equal (with delta).

`public static assertNotEqualsWithDelta(mixed $expected, mixed $actual, float $delta[, string $message = '' ]) : void`

##### Parameters

$expected : mixed
$actual : mixed
$delta : float
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertNotFalse()

Assert.php : 1101

Asserts that a condition is not false.

`public static assertNotFalse(mixed $condition[, string $message = '' ]) : void`

##### Parameters

$condition : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  !false $condition

##### Return values

void —

#### assertNotInstanceOf()

Assert.php : 1394

Asserts that a variable is not of a given type.

`public static assertNotInstanceOf(string $expected, mixed $actual[, string $message = '' ]) : void`

##### Parameters

$expected : string
$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException
psalm-template

  ExpectedType of object

psalm-param

  class-string $expected

psalm-assert

  !ExpectedType $actual

##### Return values

void —

#### assertNotIsReadable()

Assert.php : 762

Asserts that a file/dir exists and is not readable.

`public static assertNotIsReadable(string $filename[, string $message = '' ]) : void`

##### Parameters

$filename : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
codeCoverageIgnore
deprecated

  https://github.com/sebastianbergmann/phpunit/issues/4062

##### Return values

void —

#### assertNotIsWritable()

Assert.php : 801

Asserts that a file/dir exists and is not writable.

`public static assertNotIsWritable(string $filename[, string $message = '' ]) : void`

##### Parameters

$filename : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
codeCoverageIgnore
deprecated

  https://github.com/sebastianbergmann/phpunit/issues/4065

##### Return values

void —

#### assertNotNull()

Assert.php : 1127

Asserts that a variable is not null.

`public static assertNotNull(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  !null $actual

##### Return values

void —

#### assertNotRegExp()

Assert.php : 1872

Asserts that a string does not match a given regular expression.

`public static assertNotRegExp(string $pattern, string $string[, string $message = '' ]) : void`

##### Parameters

$pattern : string
$string : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
codeCoverageIgnore
deprecated

  https://github.com/sebastianbergmann/phpunit/issues/4089

##### Return values

void —

#### assertNotSame()

Assert.php : 1344

Asserts that two variables do not have the same type and value.

`public static assertNotSame(mixed $expected, mixed $actual[, string $message = '' ]) : void`

Used on objects, it asserts that two variables do not reference the same object.

##### Parameters

$expected : mixed
$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertNotSameSize()

Assert.php : 1924

Assert that the size of two arrays (or `Countable` or `Traversable` objects) is not the same.

`public static assertNotSameSize(Countable|iteratable<string|int, mixed> $expected, Countable|iteratable<string|int, mixed> $actual[, string $message = '' ]) : void`

##### Parameters

$expected : Countable|iteratable<string|int, mixed>
$actual : Countable|iteratable<string|int, mixed>
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException

##### Return values

void —

#### assertNotTrue()

Assert.php : 1075

Asserts that a condition is not true.

`public static assertNotTrue(mixed $condition[, string $message = '' ]) : void`

##### Parameters

$condition : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  !true $condition

##### Return values

void —

#### assertNull()

Assert.php : 1114

Asserts that a variable is null.

`public static assertNull(mixed $actual[, string $message = '' ]) : void`

##### Parameters

$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  null $actual

##### Return values

void —

#### assertObjectEquals()

Assert.php : 435
`public static assertObjectEquals(object $expected, object $actual[, string $method = 'equals' ][, string $message = '' ]) : void`

##### Parameters

$expected : object
$actual : object
$method : string = 'equals'
$message : string = ''

##### Tags

throws
  ExpectationFailedException

##### Return values

void —

#### assertObjectHasAttribute()

Assert.php : 1270

Asserts that an object has a specified attribute.

`public static assertObjectHasAttribute(string $attributeName, object $object[, string $message = '' ]) : void`

##### Parameters

$attributeName : string
$object : object
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException

##### Return values

void —

#### assertObjectNotHasAttribute()

Assert.php : 1296

Asserts that an object does not have a specified attribute.

`public static assertObjectNotHasAttribute(string $attributeName, object $object[, string $message = '' ]) : void`

##### Parameters

$attributeName : string
$object : object
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException

##### Return values

void —

#### assertRegExp()

Assert.php : 1838

Asserts that a string matches a given regular expression.

`public static assertRegExp(string $pattern, string $string[, string $message = '' ]) : void`

##### Parameters

$pattern : string
$string : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
codeCoverageIgnore
deprecated

  https://github.com/sebastianbergmann/phpunit/issues/4086

##### Return values

void —

#### assertSame()

Assert.php : 1327

Asserts that two variables have the same type and value.

`public static assertSame(mixed $expected, mixed $actual[, string $message = '' ]) : void`

Used on objects, it asserts that two variables reference the same object.

##### Parameters

$expected : mixed
$actual : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-template

  ExpectedType

psalm-param

  ExpectedType $expected

psalm-assert

  =ExpectedType $actual

##### Return values

void —

#### assertSameSize()

Assert.php : 1896

Assert that the size of two arrays (or `Countable` or `Traversable` objects) is the same.

`public static assertSameSize(Countable|iteratable<string|int, mixed> $expected, Countable|iteratable<string|int, mixed> $actual[, string $message = '' ]) : void`

##### Parameters

$expected : Countable|iteratable<string|int, mixed>
$actual : Countable|iteratable<string|int, mixed>
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringContainsString()

Assert.php : 2046
`public static assertStringContainsString(string $needle, string $haystack[, string $message = '' ]) : void`

##### Parameters

$needle : string
$haystack : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringContainsStringIgnoringCase()

Assert.php : 2057
`public static assertStringContainsStringIgnoringCase(string $needle, string $haystack[, string $message = '' ]) : void`

##### Parameters

$needle : string
$haystack : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringEndsNotWith()

Assert.php : 2103

Asserts that a string ends not with a given suffix.

`public static assertStringEndsNotWith(string $suffix, string $string[, string $message = '' ]) : void`

##### Parameters

$suffix : string
$string : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringEndsWith()

Assert.php : 2092

Asserts that a string ends with a given suffix.

`public static assertStringEndsWith(string $suffix, string $string[, string $message = '' ]) : void`

##### Parameters

$suffix : string
$string : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringEqualsFile()

Assert.php : 635

Asserts that the contents of a string is equal to the contents of a file.

`public static assertStringEqualsFile(string $expectedFile, string $actualString[, string $message = '' ]) : void`

##### Parameters

$expectedFile : string
$actualString : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringEqualsFileCanonicalizing()

Assert.php : 651

Asserts that the contents of a string is equal to the contents of a file (canonicalizing).

`public static assertStringEqualsFileCanonicalizing(string $expectedFile, string $actualString[, string $message = '' ]) : void`

##### Parameters

$expectedFile : string
$actualString : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringEqualsFileIgnoringCase()

Assert.php : 667

Asserts that the contents of a string is equal to the contents of a file (ignoring case).

`public static assertStringEqualsFileIgnoringCase(string $expectedFile, string $actualString[, string $message = '' ]) : void`

##### Parameters

$expectedFile : string
$actualString : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringMatchesFormat()

Assert.php : 1949

Asserts that a string matches a given format string.

`public static assertStringMatchesFormat(string $format, string $string[, string $message = '' ]) : void`

##### Parameters

$format : string
$string : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringMatchesFormatFile()

Assert.php : 1977

Asserts that a string matches a given format file.

`public static assertStringMatchesFormatFile(string $formatFile, string $string[, string $message = '' ]) : void`

##### Parameters

$formatFile : string
$string : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringNotContainsString()

Assert.php : 2068
`public static assertStringNotContainsString(string $needle, string $haystack[, string $message = '' ]) : void`

##### Parameters

$needle : string
$haystack : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringNotContainsStringIgnoringCase()

Assert.php : 2079
`public static assertStringNotContainsStringIgnoringCase(string $needle, string $haystack[, string $message = '' ]) : void`

##### Parameters

$needle : string
$haystack : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringNotEqualsFile()

Assert.php : 683

Asserts that the contents of a string is not equal to the contents of a file.

`public static assertStringNotEqualsFile(string $expectedFile, string $actualString[, string $message = '' ]) : void`

##### Parameters

$expectedFile : string
$actualString : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringNotEqualsFileCanonicalizing()

Assert.php : 701

Asserts that the contents of a string is not equal to the contents of a file (canonicalizing).

`public static assertStringNotEqualsFileCanonicalizing(string $expectedFile, string $actualString[, string $message = '' ]) : void`

##### Parameters

$expectedFile : string
$actualString : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringNotEqualsFileIgnoringCase()

Assert.php : 719

Asserts that the contents of a string is not equal to the contents of a file (ignoring case).

`public static assertStringNotEqualsFileIgnoringCase(string $expectedFile, string $actualString[, string $message = '' ]) : void`

##### Parameters

$expectedFile : string
$actualString : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringNotMatchesFormat()

Assert.php : 1960

Asserts that a string does not match a given format string.

`public static assertStringNotMatchesFormat(string $format, string $string[, string $message = '' ]) : void`

##### Parameters

$format : string
$string : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringNotMatchesFormatFile()

Assert.php : 1996

Asserts that a string does not match a given format string.

`public static assertStringNotMatchesFormatFile(string $formatFile, string $string[, string $message = '' ]) : void`

##### Parameters

$formatFile : string
$string : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringStartsNotWith()

Assert.php : 2031

Asserts that a string starts not with a given prefix.

`public static assertStringStartsNotWith(string $prefix, string $string[, string $message = '' ]) : void`

##### Parameters

$prefix : string
$string : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertStringStartsWith()

Assert.php : 2017

Asserts that a string starts with a given prefix.

`public static assertStringStartsWith(string $prefix, string $string[, string $message = '' ]) : void`

##### Parameters

$prefix : string
$string : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertThat()

Assert.php : 2340

Evaluates a PHPUnit\Framework\Constraint matcher object.

`public static assertThat(mixed $value, Constraint $constraint[, string $message = '' ]) : void`

##### Parameters

$value : mixed
$constraint : Constraint
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertTrue()

Assert.php : 1062

Asserts that a condition is true.

`public static assertTrue(mixed $condition[, string $message = '' ]) : void`

##### Parameters

$condition : mixed
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  ExpectationFailedException
psalm-assert

  true $condition

##### Return values

void —

#### assertXmlFileEqualsXmlFile()

Assert.php : 2121

Asserts that two XML files are equal.

`public static assertXmlFileEqualsXmlFile(string $expectedFile, string $actualFile[, string $message = '' ]) : void`

##### Parameters

$expectedFile : string
$actualFile : string
$message : string = ''

##### Tags

throws
  InvalidArgumentException
throws
  Exception
throws
  ExpectationFailedException

##### Return values

void —

#### assertXmlFileNotEqualsXmlFile()

Assert.php : 2136

Asserts that two XML files are not equal.

`public static assertXmlFileNotEqualsXmlFile(string $expectedFile, string $actualFile[, string $message = '' ]) : void`

##### Parameters

$expectedFile : string
$actualFile : string
$message : string = ''

##### Tags

throws
  Exception
throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertXmlStringEqualsXmlFile()

Assert.php : 2153

Asserts that two XML documents are equal.

`public static assertXmlStringEqualsXmlFile(string $expectedFile, DOMDocument|string $actualXml[, string $message = '' ]) : void`

##### Parameters

$expectedFile : string
$actualXml : DOMDocument|string
$message : string = ''

##### Tags

throws
  Exception
throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertXmlStringEqualsXmlString()

Assert.php : 2202

Asserts that two XML documents are equal.

`public static assertXmlStringEqualsXmlString(DOMDocument|string $expectedXml, DOMDocument|string $actualXml[, string $message = '' ]) : void`

##### Parameters

$expectedXml : DOMDocument|string
$actualXml : DOMDocument|string
$message : string = ''

##### Tags

throws
  Exception
throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertXmlStringNotEqualsXmlFile()

Assert.php : 2177

Asserts that two XML documents are not equal.

`public static assertXmlStringNotEqualsXmlFile(string $expectedFile, DOMDocument|string $actualXml[, string $message = '' ]) : void`

##### Parameters

$expectedFile : string
$actualXml : DOMDocument|string
$message : string = ''

##### Tags

throws
  Exception
throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### assertXmlStringNotEqualsXmlString()

Assert.php : 2233

Asserts that two XML documents are not equal.

`public static assertXmlStringNotEqualsXmlString(DOMDocument|string $expectedXml, DOMDocument|string $actualXml[, string $message = '' ]) : void`

##### Parameters

$expectedXml : DOMDocument|string
$actualXml : DOMDocument|string
$message : string = ''

##### Tags

throws
  Exception
throws
  InvalidArgumentException
throws
  ExpectationFailedException

##### Return values

void —

#### at()

TestCase.php : 422

Returns a matcher that matches when the method is executed at the given index.

`public static at(int $index) : InvokedAtIndex`

##### Parameters

$index : int

##### Tags

deprecated

  https://github.com/sebastianbergmann/phpunit/issues/4297

codeCoverageIgnore

##### Return values

InvokedAtIndex —

#### atLeast()

TestCase.php : 374

Returns a matcher that matches when the method is executed at least N times.

`public static atLeast(int $requiredInvocations) : InvokedAtLeastCount`

##### Parameters

$requiredInvocations : int

##### Return values

InvokedAtLeastCount —

#### atLeastOnce()

TestCase.php : 384

Returns a matcher that matches when the method is executed at least once.

`public static atLeastOnce() : InvokedAtLeastOnce`

##### Return values

InvokedAtLeastOnce —

#### atMost()

TestCase.php : 410

Returns a matcher that matches when the method is executed at most N times.

`public static atMost(int $allowedInvocations) : InvokedAtMostCount`

##### Parameters

$allowedInvocations : int

##### Return values

InvokedAtMostCount —

#### callback()

Assert.php : 2544
`public static callback(callable $callback) : Callback`

##### Parameters

$callback : callable

##### Tags

psalm-template

  CallbackInput of mixed

psalm-param

  callable(CallbackInput $callback): bool $callback

psalm-return

  Callback

##### Return values

Callback —

#### classHasAttribute()

Assert.php : 2665
`public static classHasAttribute(string $attributeName) : ClassHasAttribute`

##### Parameters

$attributeName : string

##### Return values

ClassHasAttribute —

#### classHasStaticAttribute()

Assert.php : 2670
`public static classHasStaticAttribute(string $attributeName) : ClassHasStaticAttribute`

##### Parameters

$attributeName : string

##### Return values

ClassHasStaticAttribute —

#### containsEqual()

Assert.php : 2579
`public static containsEqual(mixed $value) : TraversableContainsEqual`

##### Parameters

$value : mixed

##### Return values

TraversableContainsEqual —

#### containsIdentical()

Assert.php : 2584
`public static containsIdentical(mixed $value) : TraversableContainsIdentical`

##### Parameters

$value : mixed

##### Return values

TraversableContainsIdentical —

#### containsOnly()

Assert.php : 2589
`public static containsOnly(string $type) : TraversableContainsOnly`

##### Parameters

$type : string

##### Return values

TraversableContainsOnly —

#### containsOnlyInstancesOf()

Assert.php : 2594
`public static containsOnlyInstancesOf(string $className) : TraversableContainsOnly`

##### Parameters

$className : string

##### Return values

TraversableContainsOnly —

#### count()

TestCase.php : 571
`public count() : int`

##### Return values

int —

#### countOf()

Assert.php : 2733
`public static countOf(int $count) : Count`

##### Parameters

$count : int

##### Return values

Count —

#### directoryExists()

Assert.php : 2642
`public static directoryExists() : DirectoryExists`

##### Return values

DirectoryExists —

#### equalTo()

Assert.php : 2607
`public static equalTo(mixed $value) : IsEqual`

##### Parameters

$value : mixed

##### Return values

IsEqual —

#### equalToCanonicalizing()

Assert.php : 2612
`public static equalToCanonicalizing(mixed $value) : IsEqualCanonicalizing`

##### Parameters

$value : mixed

##### Return values

IsEqualCanonicalizing —

#### equalToIgnoringCase()

Assert.php : 2617
`public static equalToIgnoringCase(mixed $value) : IsEqualIgnoringCase`

##### Parameters

$value : mixed

##### Return values

IsEqualIgnoringCase —

#### equalToWithDelta()

Assert.php : 2622
`public static equalToWithDelta(mixed $value, float $delta) : IsEqualWithDelta`

##### Parameters

$value : mixed
$delta : float

##### Return values

IsEqualWithDelta —

#### exactly()

TestCase.php : 401

Returns a matcher that matches when the method is executed exactly $count times.

`public static exactly(int $count) : InvokedCount`

##### Parameters

$count : int

##### Return values

InvokedCount —

#### expectDeprecation()

TestCase.php : 660
`public expectDeprecation() : void`

##### Return values

void —

#### expectDeprecationMessage()

TestCase.php : 665
`public expectDeprecationMessage(string $message) : void`

##### Parameters

$message : string

##### Return values

void —

#### expectDeprecationMessageMatches()

TestCase.php : 670
`public expectDeprecationMessageMatches(string $regularExpression) : void`

##### Parameters

$regularExpression : string

##### Return values

void —

#### expectError()

TestCase.php : 705
`public expectError() : void`

##### Return values

void —

#### expectErrorMessage()

TestCase.php : 710
`public expectErrorMessage(string $message) : void`

##### Parameters

$message : string

##### Return values

void —

#### expectErrorMessageMatches()

TestCase.php : 715
`public expectErrorMessageMatches(string $regularExpression) : void`

##### Parameters

$regularExpression : string

##### Return values

void —

#### expectException()

TestCase.php : 596
`public expectException(string $exception) : void`

##### Parameters

$exception : string

##### Tags

psalm-param

  class-string<\Throwable> $exception

##### Return values

void —

#### expectExceptionCode()

TestCase.php : 628
`public expectExceptionCode(int|string $code) : void`

##### Parameters

$code : int|string

##### Return values

void —

#### expectExceptionMessage()

TestCase.php : 633
`public expectExceptionMessage(string $message) : void`

##### Parameters

$message : string

##### Return values

void —

#### expectExceptionMessageMatches()

TestCase.php : 638
`public expectExceptionMessageMatches(string $regularExpression) : void`

##### Parameters

$regularExpression : string

##### Return values

void —

#### expectExceptionObject()

TestCase.php : 648

Sets up an expectation for an exception to be raised by the code under test.

`public expectExceptionObject(Exception $exception) : void`

Information for expected exception class, expected exception message, and expected exception code are retrieved from a given Exception object.

##### Parameters

$exception : Exception

##### Return values

void —

#### expectNotice()

TestCase.php : 675
`public expectNotice() : void`

##### Return values

void —

#### expectNoticeMessage()

TestCase.php : 680
`public expectNoticeMessage(string $message) : void`

##### Parameters

$message : string

##### Return values

void —

#### expectNoticeMessageMatches()

TestCase.php : 685
`public expectNoticeMessageMatches(string $regularExpression) : void`

##### Parameters

$regularExpression : string

##### Return values

void —

#### expectNotToPerformAssertions()

TestCase.php : 655
`public expectNotToPerformAssertions() : void`

##### Return values

void —

#### expectOutputRegex()

TestCase.php : 583
`public expectOutputRegex(string $expectedRegex) : void`

##### Parameters

$expectedRegex : string

##### Return values

void —

#### expectOutputString()

TestCase.php : 588
`public expectOutputString(string $expectedString) : void`

##### Parameters

$expectedString : string

##### Return values

void —

#### expectWarning()

TestCase.php : 690
`public expectWarning() : void`

##### Return values

void —

#### expectWarningMessage()

TestCase.php : 695
`public expectWarningMessage(string $message) : void`

##### Parameters

$message : string

##### Return values

void —

#### expectWarningMessageMatches()

TestCase.php : 700
`public expectWarningMessageMatches(string $regularExpression) : void`

##### Parameters

$regularExpression : string

##### Return values

void —

#### fail()

Assert.php : 2750

Fails a test with the given message.

`public static fail([string $message = '' ]) : void`

##### Parameters

$message : string = ''

##### Tags

throws
  AssertionFailedError
psalm-return

  never-return

##### Return values

void —

#### fileExists()

Assert.php : 2647
`public static fileExists() : FileExists`

##### Return values

FileExists —

#### getActualOutputForAssertion()

TestCase.php : 576
`public getActualOutputForAssertion() : string`

##### Return values

string —

#### getCount()

Assert.php : 2792

Return the current assertion count.

`public static getCount() : int`

##### Return values

int —

#### getMockBuilder()

TestCase.php : 918

Returns a builder object to create mock objects using a fluent interface.

`public getMockBuilder(string $className) : MockBuilder`

##### Parameters

$className : string

##### Tags

psalm-template

  RealInstanceType of object

psalm-param

  class-string $className

psalm-return

  MockBuilder

##### Return values

MockBuilder —

#### getStatus()

TestCase.php : 720
`public getStatus() : int`

##### Return values

int —

#### getStatusMessage()

TestCase.php : 730
`public getStatusMessage() : string`

##### Return values

string —

#### greaterThan()

Assert.php : 2652
`public static greaterThan(mixed $value) : GreaterThan`

##### Parameters

$value : mixed

##### Return values

GreaterThan —

#### greaterThanOrEqual()

Assert.php : 2657
`public static greaterThanOrEqual(mixed $value) : LogicalOr`

##### Parameters

$value : mixed

##### Return values

LogicalOr —

#### hasFailed()

TestCase.php : 735
`public hasFailed() : bool`

##### Return values

bool —

#### identicalTo()

Assert.php : 2680
`public static identicalTo(mixed $value) : IsIdentical`

##### Parameters

$value : mixed

##### Return values

IsIdentical —

#### isEmpty()

Assert.php : 2627
`public static isEmpty() : IsEmpty`

##### Return values

IsEmpty —

#### isFalse()

Assert.php : 2549
`public static isFalse() : IsFalse`

##### Return values

IsFalse —

#### isFinite()

Assert.php : 2564
`public static isFinite() : IsFinite`

##### Return values

IsFinite —

#### isInfinite()

Assert.php : 2569
`public static isInfinite() : IsInfinite`

##### Return values

IsInfinite —

#### isInstanceOf()

Assert.php : 2685
`public static isInstanceOf(string $className) : IsInstanceOf`

##### Parameters

$className : string

##### Return values

IsInstanceOf —

#### isJson()

Assert.php : 2554
`public static isJson() : IsJson`

##### Return values

IsJson —

#### isNan()

Assert.php : 2574
`public static isNan() : IsNan`

##### Return values

IsNan —

#### isNull()

Assert.php : 2559
`public static isNull() : IsNull`

##### Return values

IsNull —

#### isReadable()

Assert.php : 2637
`public static isReadable() : IsReadable`

##### Return values

IsReadable —

#### isTrue()

Assert.php : 2532
`public static isTrue() : IsTrue`

##### Return values

IsTrue —

#### isType()

Assert.php : 2690
`public static isType(string $type) : IsType`

##### Parameters

$type : string

##### Return values

IsType —

#### isWritable()

Assert.php : 2632
`public static isWritable() : IsWritable`

##### Return values

IsWritable —

#### lessThan()

Assert.php : 2695
`public static lessThan(mixed $value) : LessThan`

##### Parameters

$value : mixed

##### Return values

LessThan —

#### lessThanOrEqual()

Assert.php : 2700
`public static lessThanOrEqual(mixed $value) : LogicalOr`

##### Parameters

$value : mixed

##### Return values

LogicalOr —

#### logicalAnd()

Assert.php : 2492
`public static logicalAnd() : LogicalAnd`

##### Tags

throws
  Exception

##### Return values

LogicalAnd —

#### logicalNot()

Assert.php : 2512
`public static logicalNot(Constraint $constraint) : LogicalNot`

##### Parameters

$constraint : Constraint

##### Return values

LogicalNot —

#### logicalOr()

Assert.php : 2502
`public static logicalOr() : LogicalOr`

##### Return values

LogicalOr —

#### logicalXor()

Assert.php : 2517
`public static logicalXor() : LogicalXor`

##### Return values

LogicalXor —

#### markAsRisky()

TestCase.php : 725
`public markAsRisky() : void`

##### Return values

void —

#### markTestIncomplete()

Assert.php : 2764

Mark the test as incomplete.

`public static markTestIncomplete([string $message = '' ]) : void`

##### Parameters

$message : string = ''

##### Tags

throws
  IncompleteTestError
psalm-return

  never-return

##### Return values

void —

#### markTestSkipped()

Assert.php : 2777

Mark the test as skipped.

`public static markTestSkipped([string $message = '' ]) : void`

##### Parameters

$message : string = ''

##### Tags

throws
  SkippedTestError
throws
  SyntheticSkippedError
psalm-return

  never-return

##### Return values

void —

#### matches()

Assert.php : 2713
`public static matches(string $string) : StringMatchesFormatDescription`

##### Parameters

$string : string

##### Return values

StringMatchesFormatDescription —

#### matchesRegularExpression()

Assert.php : 2708
`public static matchesRegularExpression(string $pattern) : RegularExpression`

##### Parameters

$pattern : string

##### Return values

RegularExpression —

#### never()

TestCase.php : 365

Returns a matcher that matches when the method is never executed.

`public static never() : InvokedCount`

##### Return values

InvokedCount —

#### objectEquals()

Assert.php : 2738
`public static objectEquals(object $object[, string $method = 'equals' ]) : ObjectEquals`

##### Parameters

$object : object
$method : string = 'equals'

##### Return values

ObjectEquals —

#### objectHasAttribute()

Assert.php : 2675
`public static objectHasAttribute(mixed $attributeName) : ObjectHasAttribute`

##### Parameters

$attributeName : mixed

##### Return values

ObjectHasAttribute —

#### once()

TestCase.php : 392

Returns a matcher that matches when the method is executed exactly once.

`public static once() : InvokedCount`

##### Return values

InvokedCount —

#### onConsecutiveCalls()

TestCase.php : 476
`public static onConsecutiveCalls(mixed ...$args) : ConsecutiveCalls`

##### Parameters

$args : mixed

##### Return values

ConsecutiveCalls —

#### provides()

TestCase.php : 1504

Returns the normalized test name as class::method.

`public provides() : list<string|int, ExecutionOrderDependency>`

##### Return values

list<string|int, ExecutionOrderDependency> —

#### registerComparator()

TestCase.php : 925
`public registerComparator(Comparator $comparator) : void`

##### Parameters

$comparator : Comparator

##### Return values

void —

#### requires()

TestCase.php : 1518

Returns a list of normalized dependency names, class::method.

`public requires() : list<string|int, ExecutionOrderDependency>`

This list can differ from the raw dependencies as the resolver has no need for the [!][shallow]clone prefix that is filtered out during normalization.

##### Return values

list<string|int, ExecutionOrderDependency> —

#### resetCount()

Assert.php : 2800

Reset the assertion counter.

`public static resetCount() : void`

##### Return values

void —

#### returnArgument()

TestCase.php : 451
`public static returnArgument(int $argumentIndex) : ReturnArgument`

##### Parameters

$argumentIndex : int

##### Return values

ReturnArgument —

#### returnCallback()

TestCase.php : 456
`public static returnCallback(mixed $callback) : ReturnCallback`

##### Parameters

$callback : mixed

##### Return values

ReturnCallback —

#### returnSelf()

TestCase.php : 466

Returns the current object.

`public static returnSelf() : ReturnSelf`

This method is useful when mocking a fluent interface.

##### Return values

ReturnSelf —

#### returnValue()

TestCase.php : 441
`public static returnValue(mixed $value) : ReturnStub`

##### Parameters

$value : mixed

##### Return values

ReturnStub —

#### returnValueMap()

TestCase.php : 446
`public static returnValueMap(array<string|int, mixed> $valueMap) : ReturnValueMap`

##### Parameters

$valueMap : array<string|int, mixed>

##### Return values

ReturnValueMap —

#### run()

TestCase.php : 752

Runs the test case and collects the results in a TestResult object.

`public run([TestResult $result = null ]) : TestResult`

If no TestResult object is passed a new one will be created.

##### Parameters

$result : TestResult = null

##### Tags

throws
  InvalidArgumentException
throws
  UnintentionallyCoveredCodeException
throws
  InvalidArgumentException
throws
  CodeCoverageException
throws
  Exception

##### Return values

TestResult —

#### setUpBeforeClass()

TestCase.php : 499

This method is called before the first test of this test class is run.

`public static setUpBeforeClass() : void`

##### Return values

void —

#### sortId()

TestCase.php : 1484
`public sortId() : string`

##### Return values

string —

#### stringContains()

Assert.php : 2723
`public static stringContains(string $string[, bool $case = true ]) : StringContains`

##### Parameters

$string : string
$case : bool = true

##### Return values

StringContains —

#### stringEndsWith()

Assert.php : 2728
`public static stringEndsWith(string $suffix) : StringEndsWith`

##### Parameters

$suffix : string

##### Return values

StringEndsWith —

#### stringStartsWith()

Assert.php : 2718
`public static stringStartsWith(mixed $prefix) : StringStartsWith`

##### Parameters

$prefix : mixed

##### Return values

StringStartsWith —

#### tearDownAfterClass()

TestCase.php : 506

This method is called after the last test of this test class is run.

`public static tearDownAfterClass() : void`

##### Return values

void —

#### test_create_instance_with_invalid_arguments()

ShipmentTest.php : 31
`public test_create_instance_with_invalid_arguments() : void`

##### Return values

void —

#### test_create_instance_with_invalid_carrier_argument()

ShipmentTest.php : 40
`public test_create_instance_with_invalid_carrier_argument() : void`

##### Return values

void —

#### test_create_instance_without_arguments()

ShipmentTest.php : 21
`public test_create_instance_without_arguments() : void`

##### Return values

void —

#### test_create_valid_instance()

ShipmentTest.php : 59
`public test_create_valid_instance() : void`

##### Return values

void —

#### test_create_valid_instance_and_set_invalid_carrier()

ShipmentTest.php : 68
`public test_create_valid_instance_and_set_invalid_carrier() : void`

##### Return values

void —

#### test_create_valid_instance_and_set_invalid_incoterm()

ShipmentTest.php : 94
`public test_create_valid_instance_and_set_invalid_incoterm() : void`

##### Return values

void —

#### test_create_valid_instance_and_set_invalid_service()

ShipmentTest.php : 81
`public test_create_valid_instance_and_set_invalid_service() : void`

##### Return values

void —

#### test_to_array()

ShipmentTest.php : 107
`public test_to_array() : void`

##### Return values

void —

#### throwException()

TestCase.php : 471
`public static throwException(Throwable $exception) : Exception`

##### Parameters

$exception : Throwable

##### Return values

Exception —

#### toString()

TestCase.php : 548

Returns a string representation of the test case.

`public toString() : string`

##### Tags

throws
  InvalidArgumentException
throws
  Exception

##### Return values

string —

#### assertPostConditions()

TestCase.php : 531

Performs assertions shared by all tests of a test case.

`protected assertPostConditions() : void`

This method is called between test and tearDown().

##### Return values

void —

#### assertPreConditions()

TestCase.php : 522

Performs assertions shared by all tests of a test case.

`protected assertPreConditions() : void`

This method is called between setUp() and test.

##### Return values

void —

#### createConfiguredMock()

TestCase.php : 1729

Returns a configured mock object for the specified class.

`protected createConfiguredMock(string $originalClassName, array<string|int, mixed> $configuration) : MockObject`

##### Parameters

$originalClassName : string
$configuration : array<string|int, mixed>

##### Tags

psalm-template

  RealInstanceType of object

psalm-param

  class-string $originalClassName

psalm-return

  MockObject&RealInstanceType

##### Return values

MockObject —

#### createMock()

TestCase.php : 1717

Returns a mock object for the specified class.

`protected createMock(string $originalClassName) : MockObject`

##### Parameters

$originalClassName : string

##### Tags

psalm-template

  RealInstanceType of object

psalm-param

  class-string $originalClassName

psalm-return

  MockObject&RealInstanceType

##### Return values

MockObject —

#### createPartialMock()

TestCase.php : 1749

Returns a partial mock object for the specified class.

`protected createPartialMock(string $originalClassName, array<string|int, string> $methods) : MockObject`

##### Parameters

$originalClassName : string
$methods : array<string|int, string>

##### Tags

psalm-template

  RealInstanceType of object

psalm-param

  class-string $originalClassName

psalm-return

  MockObject&RealInstanceType

##### Return values

MockObject —

#### createStub()

TestCase.php : 1705

Makes configurable stub for the specified class.

`protected createStub(string $originalClassName) : Stub`

##### Parameters

$originalClassName : string

##### Tags

psalm-template

  RealInstanceType of object

psalm-param

  class-string $originalClassName

psalm-return

  Stub&RealInstanceType

##### Return values

Stub —

#### createTestProxy()

TestCase.php : 1797

Returns a test proxy for the specified class.

`protected createTestProxy(string $originalClassName[, array<string|int, mixed> $constructorArguments = [] ]) : MockObject`

##### Parameters

$originalClassName : string
$constructorArguments : array<string|int, mixed> = []

##### Tags

psalm-template

  RealInstanceType of object

psalm-param

  class-string $originalClassName

psalm-return

  MockObject&RealInstanceType

##### Return values

MockObject —

#### getMockClass()

TestCase.php : 1814

Mocks the specified class and returns the name of the mocked class.

`protected getMockClass(string $originalClassName[, null|array<string|int, mixed> $methods = [] ][, array<string|int, mixed> $arguments = [] ][, string $mockClassName = '' ][, bool $callOriginalConstructor = false ][, bool $callOriginalClone = true ][, bool $callAutoload = true ][, bool $cloneArguments = false ]) : string`

##### Parameters

$originalClassName : string
$methods : null|array<string|int, mixed> = []

  $methods

$arguments : array<string|int, mixed> = []
$mockClassName : string = ''
$callOriginalConstructor : bool = false
$callOriginalClone : bool = true
$callAutoload : bool = true
$cloneArguments : bool = false

##### Tags

psalm-template

  RealInstanceType of object

psalm-param

  class-string|string $originalClassName

psalm-return

  class-string<MockObject&RealInstanceType>

##### Return values

string —

#### getMockForAbstractClass()

TestCase.php : 1841

Returns a mock object for the specified abstract class with all abstract methods of the class mocked. Concrete methods are not mocked by default.

`protected getMockForAbstractClass(string $originalClassName[, array<string|int, mixed> $arguments = [] ][, string $mockClassName = '' ][, bool $callOriginalConstructor = true ][, bool $callOriginalClone = true ][, bool $callAutoload = true ][, array<string|int, mixed> $mockedMethods = [] ][, bool $cloneArguments = false ]) : MockObject`

To mock concrete methods, use the 7th parameter ($mockedMethods).

##### Parameters

$originalClassName : string
$arguments : array<string|int, mixed> = []
$mockClassName : string = ''
$callOriginalConstructor : bool = true
$callOriginalClone : bool = true
$callAutoload : bool = true
$mockedMethods : array<string|int, mixed> = []
$cloneArguments : bool = false

##### Tags

psalm-template

  RealInstanceType of object

psalm-param

  class-string $originalClassName

psalm-return

  MockObject&RealInstanceType

##### Return values

MockObject —

#### getMockForTrait()

TestCase.php : 1910

Returns a mock object for the specified trait with all abstract methods of the trait mocked. Concrete methods to mock can be specified with the `$mockedMethods` parameter.

`protected getMockForTrait(string $traitName[, array<string|int, mixed> $arguments = [] ][, string $mockClassName = '' ][, bool $callOriginalConstructor = true ][, bool $callOriginalClone = true ][, bool $callAutoload = true ][, array<string|int, mixed> $mockedMethods = [] ][, bool $cloneArguments = false ]) : MockObject`

##### Parameters

$traitName : string
$arguments : array<string|int, mixed> = []
$mockClassName : string = ''
$callOriginalConstructor : bool = true
$callOriginalClone : bool = true
$callAutoload : bool = true
$mockedMethods : array<string|int, mixed> = []
$cloneArguments : bool = false

##### Tags

psalm-param

  trait-string $traitName

##### Return values

MockObject —

#### getMockFromWsdl()

TestCase.php : 1868

Returns a mock object based on the given WSDL file.

`protected getMockFromWsdl(string $wsdlFile[, string $originalClassName = '' ][, string $mockClassName = '' ][, array<string|int, mixed> $methods = [] ][, bool $callOriginalConstructor = true ][, array<string|int, mixed> $options = [] ]) : MockObject`

##### Parameters

$wsdlFile : string
$originalClassName : string = ''
$mockClassName : string = ''
$methods : array<string|int, mixed> = []
$callOriginalConstructor : bool = true
$options : array<string|int, mixed> = []

##### Tags

psalm-template

  RealInstanceType of object

psalm-param

  class-string|string $originalClassName

psalm-return

  MockObject&RealInstanceType

##### Return values

MockObject —

#### getObjectForTrait()

TestCase.php : 1935

Returns an object for the specified trait.

`protected getObjectForTrait(string $traitName[, array<string|int, mixed> $arguments = [] ][, string $traitClassName = '' ][, bool $callOriginalConstructor = true ][, bool $callOriginalClone = true ][, bool $callAutoload = true ]) : object`

##### Parameters

$traitName : string
$arguments : array<string|int, mixed> = []
$traitClassName : string = ''
$callOriginalConstructor : bool = true
$callOriginalClone : bool = true
$callAutoload : bool = true

##### Tags

psalm-param

  trait-string $traitName

##### Return values

object —

#### iniSet()

TestCase.php : 1646

This method is a wrapper for the ini_set() function that automatically resets the modified php.ini setting to its original value after the test is run.

`protected iniSet(string $varName, string $newValue) : void`

##### Parameters

$varName : string
$newValue : string

##### Tags

throws
  Exception

##### Return values

void —

#### onNotSuccessfulTest()

TestCase.php : 1981

This method is called when a test method did not execute successfully.

`protected onNotSuccessfulTest(Throwable $t) : void`

##### Parameters

$t : Throwable

##### Tags

throws
  Throwable

##### Return values

void —

#### prophesize()

TestCase.php : 1955
`protected prophesize([string|null $classOrInterface = null ]) : ObjectProphecy`

##### Parameters

$classOrInterface : string|null = null

##### Tags

throws
  ClassNotFoundException
throws
  DoubleException
throws
  InterfaceNotFoundException
psalm-param

  class-string|null $classOrInterface

##### Return values

ObjectProphecy —

#### recordDoubledType()

TestCase.php : 1986
`protected recordDoubledType(string $originalClassName) : void`

##### Parameters

$originalClassName : string

##### Return values

void —

#### runTest()

TestCase.php : 1532

Override to run the test and assert its state.

`protected runTest() : mixed`

##### Tags

throws
  InvalidArgumentException
throws
  AssertionFailedError
throws
  Exception
throws
  ExpectationFailedException
throws
  Throwable

##### Return values

mixed —

#### setLocale()

TestCase.php : 1669

This method is a wrapper for the setlocale() function that automatically resets the locale to its original value after the test is run.

`protected setLocale(mixed ...$args) : void`

##### Parameters

$args : mixed

##### Tags

throws
  Exception

##### Return values

void —

#### setUp()

TestCase.php : 513

This method is called before each test.

`protected setUp() : void`

##### Return values

void —

#### tearDown()

TestCase.php : 538

This method is called after each test.

`protected tearDown() : void`

##### Return values

void —

#### checkExceptionExpectations()

TestCase.php : 2495
`private checkExceptionExpectations(Throwable $throwable) : bool`

##### Parameters

$throwable : Throwable

##### Tags

throws
  Exception

##### Return values

bool —

#### checkRequirements()

TestCase.php : 2027
`private checkRequirements() : void`

##### Tags

throws
  SkippedTestError
throws
  SyntheticSkippedError
throws
  Warning

##### Return values

void —

#### cleanupIniSettings()

TestCase.php : 2474
`private cleanupIniSettings() : void`

##### Return values

void —

#### cleanupLocaleSettings()

TestCase.php : 2483
`private cleanupLocaleSettings() : void`

##### Return values

void —

#### compareGlobalStateSnapshotPart()

TestCase.php : 2372
`private compareGlobalStateSnapshotPart(array<string|int, mixed> $before, array<string|int, mixed> $after, string $header) : void`

##### Parameters

$before : array<string|int, mixed>
$after : array<string|int, mixed>
$header : string

##### Tags

throws
  RiskyTestError

##### Return values

void —

#### compareGlobalStateSnapshots()

TestCase.php : 2342
`private compareGlobalStateSnapshots(Snapshot $before, Snapshot $after) : void`

##### Parameters

$before : Snapshot
$after : Snapshot

##### Tags

throws
  InvalidArgumentException
throws
  RiskyTestError

##### Return values

void —

#### createGlobalStateSnapshot()

TestCase.php : 2279
`private createGlobalStateSnapshot(bool $backupGlobals) : Snapshot`

##### Parameters

$backupGlobals : bool

##### Return values

Snapshot —

#### createMockObject()

TestCase.php : 2572
`private createMockObject(string $originalClassName) : MockObject`

##### Parameters

$originalClassName : string

##### Tags

psalm-template

  RealInstanceType of object

psalm-param

  class-string $originalClassName

psalm-return

  MockObject&RealInstanceType

##### Return values

MockObject —

#### createWarning()

Assert.php : 2842
`private static createWarning(string $warning) : void`

##### Parameters

$warning : string

##### Tags

codeCoverageIgnore

##### Return values

void —

#### detectLocationHint()

Assert.php : 2805
`private static detectLocationHint(string $message) : array<string|int, mixed>|null`

##### Parameters

$message : string

##### Return values

array<string|int, mixed>|null —

#### get_valid_instance()

ShipmentTest.php : 118
`private get_valid_instance() : mixed`

##### Return values

mixed —

#### getMockObjectGenerator()

TestCase.php : 2187

Get the mock object generator, creating it if it doesn't exist.

`private getMockObjectGenerator() : Generator`

##### Return values

Generator —

#### getProphet()

TestCase.php : 2389
`private getProphet() : Prophet`

##### Return values

Prophet —

#### handleDependencies()

TestCase.php : 2043
`private handleDependencies() : bool`

##### Return values

bool —

#### isCallableTestMethod()

TestCase.php : 2536
`private isCallableTestMethod(string $dependency) : bool`

##### Parameters

$dependency : string

##### Return values

bool —

#### isValidClassAttributeName()

Assert.php : 2834
`private static isValidClassAttributeName(string $attributeName) : bool`

##### Parameters

$attributeName : string

##### Return values

bool —

#### isValidObjectAttributeName()

Assert.php : 2829
`private static isValidObjectAttributeName(string $attributeName) : bool`

##### Parameters

$attributeName : string

##### Return values

bool —

#### markSkippedForMissingDependency()

TestCase.php : 2144
`private markSkippedForMissingDependency(ExecutionOrderDependency $dependency) : void`

##### Parameters

$dependency : ExecutionOrderDependency

##### Return values

void —

#### markSkippedForNotSpecifyingDependency()

TestCase.php : 2127
`private markSkippedForNotSpecifyingDependency() : void`

##### Return values

void —

#### markWarningForUncallableDependency()

TestCase.php : 2164
`private markWarningForUncallableDependency(ExecutionOrderDependency $dependency) : void`

##### Parameters

$dependency : ExecutionOrderDependency

##### Return values

void —

#### registerMockObjectsFromTestArguments()

TestCase.php : 2423
`private registerMockObjectsFromTestArguments(array<string|int, mixed> $testArguments[, array<string|int, mixed> &$visited = [] ]) : void`

##### Parameters

$testArguments : array<string|int, mixed>
$visited : array<string|int, mixed> = []

##### Tags

throws
  InvalidArgumentException
throws
  InvalidArgumentException
throws
  InvalidArgumentException

##### Return values

void —

#### restoreGlobalState()

TestCase.php : 2245
`private restoreGlobalState() : void`

##### Tags

throws
  InvalidArgumentException
throws
  RiskyTestError

##### Return values

void —

#### runInSeparateProcess()

TestCase.php : 2530
`private runInSeparateProcess() : bool`

##### Return values

bool —

#### setDoesNotPerformAssertionsFromAnnotation()

TestCase.php : 2451
`private setDoesNotPerformAssertionsFromAnnotation() : void`

##### Return values

void —

#### shouldInvocationMockerBeReset()

TestCase.php : 2401
`private shouldInvocationMockerBeReset(MockObject $mock) : bool`

##### Parameters

$mock : MockObject

##### Tags

throws
  InvalidArgumentException

##### Return values

bool —

#### snapshotGlobalState()

TestCase.php : 2231
`private snapshotGlobalState() : void`

##### Return values

void —

#### startOutputBuffering()

TestCase.php : 2196
`private startOutputBuffering() : void`

##### Return values

void —

#### stopOutputBuffering()

TestCase.php : 2207
`private stopOutputBuffering() : void`

##### Tags

throws
  RiskyTestError

##### Return values

void —

#### unregisterCustomComparators()

TestCase.php : 2463
`private unregisterCustomComparators() : void`

##### Return values

void —

#### verifyMockObjects()

TestCase.php : 1994
`private verifyMockObjects() : void`

##### Tags

throws
  Throwable

##### Return values

void —

## Search results