mirror of
https://github.com/composer/composer
synced 2025-05-09 00:22:53 +00:00
Add types to Repository
tests (#10227)
This commit is contained in:
parent
3d9e9ba66f
commit
d51c7685da
15 changed files with 133 additions and 23 deletions
|
@ -18,6 +18,7 @@ use Composer\Util\Filesystem;
|
|||
|
||||
class RepositoryManagerTest extends TestCase
|
||||
{
|
||||
/** @var string */
|
||||
protected $tmpdir;
|
||||
|
||||
public function setUp()
|
||||
|
@ -51,7 +52,11 @@ class RepositoryManagerTest extends TestCase
|
|||
}
|
||||
|
||||
/**
|
||||
* @dataProvider creationCases
|
||||
* @dataProvider provideRepoCreationTestCases
|
||||
*
|
||||
* @param string $type
|
||||
* @param array<string, mixed> $options
|
||||
* @param string|null $exception
|
||||
*/
|
||||
public function testRepoCreation($type, $options, $exception = null)
|
||||
{
|
||||
|
@ -89,7 +94,7 @@ class RepositoryManagerTest extends TestCase
|
|||
$this->assertInstanceOf('Composer\Repository\RepositoryInterface', $rm->createRepository($type, $options));
|
||||
}
|
||||
|
||||
public function creationCases()
|
||||
public function provideRepoCreationTestCases()
|
||||
{
|
||||
$cases = array(
|
||||
array('composer', array('url' => 'http://example.org')),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue