Fixtures
  • References/PHP/PHPUnit/Guides

One of the most time-consuming parts of writing tests is writing the code to set the world up in a known state and then return it to its original state when the test is complete

2025-01-10 15:47:30
Code Coverage Analysis
  • References/PHP/PHPUnit/Guides

In computer science, code coverage is a measure used to

2025-01-10 15:47:30
Incomplete and Skipped Tests
  • References/PHP/PHPUnit/Guides

Incomplete Tests When you are working on a new test case class, you might want to begin by writing empty test methods such

2025-01-10 15:47:30
@after
  • References/PHP/PHPUnit/Annotations

@after The @after annotation can be used to specify methods that should be called after each test method in a

2025-01-10 15:47:30
@group
  • References/PHP/PHPUnit/Annotations

@group A test can be tagged as belonging to one or more groups using the @group annotation like this

2025-01-10 15:47:30
@backupGlobals
  • References/PHP/PHPUnit/Annotations

@backupGlobals The backup and restore operations for global variables can be completely disabled for all tests of a test case class like this

2025-01-10 15:47:30
assertInstanceOf()
  • References/PHP/PHPUnit/Assertions

assertInstanceOf() assertInstanceOf($expected, $actual[, $message = ''])

2025-01-10 15:47:30
@small
  • References/PHP/PHPUnit/Annotations

@small The @small annotation is an alias for @group small. A small test must not

2025-01-10 15:47:30
@runTestsInSeparateProcesses
  • References/PHP/PHPUnit/Annotations

@runTestsInSeparateProcesses Indicates that all tests in a test class should be run in a separate PHP process.

2025-01-10 15:47:30
assertArraySubset()
  • References/PHP/PHPUnit/Assertions

assertArraySubset() assertArraySubset(array $subset, array $array[, bool $strict = ''

2025-01-10 15:47:30