-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Issue #3118477 by mondrake, Mile23: RegistryTest, RegistryLegacyTest …
…both define the same class, use mock instead (cherry picked from commit 0a65cd6076dbb2579634f2b4390f1532db11d9f6)
- Loading branch information
Showing
3 changed files
with
62 additions
and
63 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
<?php | ||
|
||
namespace Drupal\Tests\Core\Test; | ||
|
||
use Drupal\Tests\UnitTestCase; | ||
use Symfony\Component\Process\Process; | ||
|
||
/** | ||
* @group TestSuites | ||
* @group Test | ||
*/ | ||
class PhpUnitCliTest extends UnitTestCase { | ||
|
||
/** | ||
* Ensure that the test suites are able to discover tests without incident. | ||
*/ | ||
public function testPhpUnitListTests() { | ||
// Generate the list of tests for all the tests the suites can discover. | ||
// The goal here is to successfully generate the list, without any | ||
// duplicate namespace errors or so forth. This keeps us from committing | ||
// tests which don't break under run-tests.sh, but do break under the | ||
// phpunit test runner tool. | ||
$process = new Process('vendor/bin/phpunit --configuration core --verbose --list-tests'); | ||
$process->setWorkingDirectory($this->root) | ||
->setTimeout(300) | ||
->setIdleTimeout(300); | ||
$process->run(); | ||
$this->assertEquals(0, $process->getExitCode(), | ||
'COMMAND: ' . $process->getCommandLine() . "\n" . | ||
'OUTPUT: ' . $process->getOutput() . "\n" . | ||
'ERROR: ' . $process->getErrorOutput() . "\n" | ||
); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters