1
0
Fork 0
mirror of https://github.com/composer/composer synced 2025-05-09 00:22:53 +00:00

ArrayLoader: handle invalid support value (#11440)

This commit is contained in:
Stephan 2023-04-26 14:26:45 +01:00 committed by GitHub
parent e0c1ad1448
commit 11879ea737
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 13 additions and 1 deletions

View file

@ -429,4 +429,16 @@ class ArrayLoaderTest extends TestCase
$package = $this->loader->load($config);
$this->assertCount(0, $package->getReplaces());
}
public function testSupportStringValue(): void
{
$config = array(
'name' => 'acme/package',
'version' => 'dev-1',
'support' => 'https://example.org',
);
$package = $this->loader->load($config);
$this->assertSame([], $package->getSupport());
}
}