Commit c128b01f authored by Gabor Hojtsy's avatar Gabor Hojtsy
Browse files

Issue #2893371 by Mile23: Several methods theoretically added to...

Issue #2893371 by Mile23: Several methods theoretically added to TestInfoParsingTest were actually not
parent 7391fbcc
<?php
/**
* @file
* Contains \Drupal\Tests\simpletest\Unit\TestInfoParsingTest.
*/
namespace Drupal\Tests\simpletest\Unit;
use Composer\Autoload\ClassLoader;
......@@ -19,7 +14,7 @@
* @coversDefaultClass \Drupal\simpletest\TestDiscovery
* @group simpletest
*/
class TestInfoParsingTest extends UnitTestCase {
class TestDiscoveryTest extends UnitTestCase {
/**
* @covers ::getTestInfo
......@@ -35,13 +30,13 @@ public function infoParserProvider() {
$tests[] = [
// Expected result.
[
'name' => 'Drupal\Tests\simpletest\Unit\TestInfoParsingTest',
'name' => 'Drupal\Tests\simpletest\Unit\TestDiscoveryTest',
'group' => 'simpletest',
'description' => 'Tests \Drupal\simpletest\TestDiscovery.',
'type' => 'PHPUnit-Unit',
],
// Classname.
'Drupal\Tests\simpletest\Unit\TestInfoParsingTest',
'Drupal\Tests\simpletest\Unit\TestDiscoveryTest',
];
// A core unit test.
......@@ -366,26 +361,6 @@ public function testGetTestClassesWithSelectedTypes() {
], $result);
}
}
class TestTestDiscovery extends TestDiscovery {
/**
* @var \Drupal\Core\Extension\Extension[]
*/
protected $extensions = [];
public function setExtensions(array $extensions) {
$this->extensions = $extensions;
}
/**
* {@inheritdoc}
*/
protected function getExtensions() {
return $this->extensions;
}
/**
* @covers ::getPhpunitTestSuite
* @dataProvider providerTestGetPhpunitTestSuite
......@@ -413,6 +388,26 @@ public function providerTestGetPhpunitTestSuite() {
}
class TestTestDiscovery extends TestDiscovery {
/**
* @var \Drupal\Core\Extension\Extension[]
*/
protected $extensions = [];
public function setExtensions(array $extensions) {
$this->extensions = $extensions;
}
/**
* {@inheritdoc}
*/
protected function getExtensions() {
return $this->extensions;
}
}
namespace Drupal\simpletest\Tests;
use Drupal\simpletest\WebTestBase;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment