mirror of
https://github.com/composer/composer
synced 2025-05-10 00:53:06 +00:00
Disable packagist.org loading by default in initTempComposer test cases if other repos are provided
This commit is contained in:
parent
7377d1f003
commit
a6d872191c
2 changed files with 7 additions and 3 deletions
|
@ -123,17 +123,17 @@ class ConfigCommandTest extends TestCase
|
|||
'vendor',
|
||||
];
|
||||
yield 'read repos by named key' => [
|
||||
['repositories' => ['foo' => ['type' => 'vcs', 'url' => 'https://example.org']]],
|
||||
['repositories' => ['foo' => ['type' => 'vcs', 'url' => 'https://example.org'], 'packagist.org' => ['type' => 'composer', 'url' => 'https://repo.packagist.org']]],
|
||||
['setting-key' => 'repositories.foo'],
|
||||
'{"type":"vcs","url":"https://example.org"}',
|
||||
];
|
||||
yield 'read repos by numeric index' => [
|
||||
['repositories' => [['type' => 'vcs', 'url' => 'https://example.org']]],
|
||||
['repositories' => [['type' => 'vcs', 'url' => 'https://example.org'], 'packagist.org' => ['type' => 'composer', 'url' => 'https://repo.packagist.org']]],
|
||||
['setting-key' => 'repos.0'],
|
||||
'{"type":"vcs","url":"https://example.org"}',
|
||||
];
|
||||
yield 'read all repos includes the default packagist' => [
|
||||
['repositories' => ['foo' => ['type' => 'vcs', 'url' => 'https://example.org']]],
|
||||
['repositories' => ['foo' => ['type' => 'vcs', 'url' => 'https://example.org'], 'packagist.org' => ['type' => 'composer', 'url' => 'https://repo.packagist.org']]],
|
||||
['setting-key' => 'repos'],
|
||||
'{"foo":{"type":"vcs","url":"https://example.org"},"packagist.org":{"type":"composer","url":"https://repo.packagist.org"}}',
|
||||
];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue