tests: adapts to collision beta 2

This commit is contained in:
Nuno Maduro
2020-06-05 18:14:27 +02:00
parent 20d2d9f3b7
commit 9bdd254007
2 changed files with 12 additions and 12 deletions

View File

@ -1,5 +1,5 @@
PASS Tests\CustomTestCase\PhpunitTest PASS Tests\CustomTestCase\ExecutedTest
✓ that gets executed ✓ that gets executed
PASS Tests\Features\AfterAll PASS Tests\Features\AfterAll
@ -24,7 +24,7 @@
✓ it sets arrays ✓ it sets arrays
✓ it gets bound to test case object with ('a') ✓ it gets bound to test case object with ('a')
✓ it gets bound to test case object with ('b') ✓ it gets bound to test case object with ('b')
✓ it truncates the description with (' fooo fooo fooo fooo fooo fooo fooo f...oo fooo') ✓ it truncates the description with ('FoooFoooFoooFoooFoooFoooFoooF...ooFooo')
✓ lazy datasets with (1) ✓ lazy datasets with (1)
✓ lazy datasets with (2) ✓ lazy datasets with (2)
✓ lazy datasets did the job right ✓ lazy datasets did the job right
@ -40,10 +40,10 @@
✓ eager wrapped registered datasets with (1) ✓ eager wrapped registered datasets with (1)
✓ eager wrapped registered datasets with (2) ✓ eager wrapped registered datasets with (2)
✓ eager registered wrapped datasets did the job right ✓ eager registered wrapped datasets did the job right
✓ lazy named datasets with ( bar object (...)) ✓ lazy named datasets with (Bar Object (...))
PASS Tests\Features\Exceptions PASS Tests\Features\Exceptions
✓ it gives access the the underlying expect exception ✓ it gives access the the underlying expectException
✓ it catch exceptions ✓ it catch exceptions
✓ it catch exceptions and messages ✓ it catch exceptions and messages
@ -64,8 +64,8 @@
✓ it has bar ✓ it has bar
PASS Tests\Features\PendingHigherOrderTests PASS Tests\Features\PendingHigherOrderTests
✓ get 'foo' → get 'bar' → assert true true ✓ get 'foo' → get 'bar' → assertTrue true
✓ get 'foo' → assert true true ✓ get 'foo' → assertTrue true
WARN Tests\Features\Skip WARN Tests\Features\Skip
✓ it do not skips ✓ it do not skips
@ -87,10 +87,10 @@
✓ it example ✓ it example
PASS Tests\PHPUnit\CustomTestCase\UsesPerDirectory PASS Tests\PHPUnit\CustomTestCase\UsesPerDirectory
✓ closure was bound to custom test case ✓ closure was bound to CustomTestCase
PASS Tests\PHPUnit\CustomTestCaseInSubFolders\SubFolder\SubFolder\UsesPerSubDirectory PASS Tests\PHPUnit\CustomTestCaseInSubFolders\SubFolder\SubFolder\UsesPerSubDirectory
✓ closure was bound to custom test case ✓ closure was bound to CustomTestCase
PASS Tests\PHPUnit\CustomTestCaseInSubFolders\SubFolder2\UsesPerFile PASS Tests\PHPUnit\CustomTestCaseInSubFolders\SubFolder2\UsesPerFile
✓ custom traits can be used ✓ custom traits can be used
@ -135,4 +135,4 @@
s visual snapshot of test suite on success s visual snapshot of test suite on success
Tests: 6 skipped, 71 passed Tests: 6 skipped, 71 passed
Time: 2.89s Time: 2.96s

View File

@ -7,7 +7,7 @@ namespace Tests\CustomTestCase;
use function PHPUnit\Framework\assertTrue; use function PHPUnit\Framework\assertTrue;
use PHPUnit\Framework\TestCase; use PHPUnit\Framework\TestCase;
class PhpunitTest extends TestCase class ExecutedTest extends TestCase
{ {
public static $executed = false; public static $executed = false;
@ -16,8 +16,8 @@ class PhpunitTest extends TestCase
{ {
self::$executed = true; self::$executed = true;
$this->assertTrue(true); assertTrue(true);
} }
} }
// register_shutdown_function(fn () => assertTrue(PhpunitTest::$executed)); // register_shutdown_function(fn () => assertTrue(ExecutedTest::$executed));