Skip to content

Commit baf4e5c

Browse files
Add test for empty test suite
1 parent 7583398 commit baf4e5c

File tree

2 files changed

+40
-0
lines changed

2 files changed

+40
-0
lines changed
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
--TEST--
2+
Empty test suite
3+
--FILE--
4+
<?php declare(strict_types=1);
5+
$_SERVER['argv'][] = '--no-configuration';
6+
$_SERVER['argv'][] = '--do-not-cache-result';
7+
$_SERVER['argv'][] = '--debug';
8+
$_SERVER['argv'][] = __DIR__ . '/fixture/empty-test-suite';
9+
10+
require __DIR__ . '/../../bootstrap.php';
11+
12+
(new PHPUnit\TextUI\Application)->run($_SERVER['argv']);
13+
--EXPECTF--
14+
PHPUnit Started (PHPUnit %s using %s)
15+
Test Runner Configured
16+
Test Runner Triggered Warning (No tests found in class "PHPUnit\TestFixture\ExecutionOrder\EmptyTestSuite\FooTest".)
17+
Test Suite Loaded (0 tests)
18+
Event Facade Sealed
19+
Test Runner Started
20+
Test Suite Sorted
21+
Test Runner Execution Started (0 tests)
22+
Test Runner Execution Finished
23+
Test Runner Finished
24+
PHPUnit Finished (Shell Exit Code: 1)
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<?php declare(strict_types=1);
2+
/*
3+
* This file is part of PHPUnit.
4+
*
5+
* (c) Sebastian Bergmann <sebastian@phpunit.de>
6+
*
7+
* For the full copyright and license information, please view the LICENSE
8+
* file that was distributed with this source code.
9+
*/
10+
namespace PHPUnit\TestFixture\ExecutionOrder\EmptyTestSuite;
11+
12+
use PHPUnit\Framework\TestCase;
13+
14+
final class FooTest extends TestCase
15+
{
16+
}

0 commit comments

Comments
 (0)