Skip to content

Commit 6f99eea

Browse files
Add failing test
1 parent 163d732 commit 6f99eea

File tree

3 files changed

+33
-0
lines changed

3 files changed

+33
-0
lines changed

Tests/Functional/Fixtures/Issue49.php

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
<?php
2+
declare(strict_types=1);
3+
4+
namespace Matthias\SymfonyServiceDefinitionValidator\Tests\Functional\Fixtures;
5+
6+
final class Issue49
7+
{
8+
public function __construct(array $values)
9+
{
10+
}
11+
}
+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
parameters:
2+
app_config:
3+
abc:
4+
- a
5+
- b
6+
- c
7+
8+
services:
9+
app.services.service_id:
10+
class: Matthias\SymfonyServiceDefinitionValidator\Tests\Functional\Fixtures\Issue49
11+
arguments:
12+
- "@=parameter('app_config')['abc']"

Tests/Functional/FunctionalTest.php

+10
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,16 @@ public function testIfTheServiceDefinitionsAreCorrectTheContainerWillBeCompiled(
5252
$this->addToAssertionCount(1);
5353
}
5454

55+
public function testIssue49(): void
56+
{
57+
$loader = new YamlFileLoader($this->container, new FileLocator(__DIR__ . '/Fixtures'));
58+
$loader->load('issue_49.yml');
59+
60+
$this->container->compile();
61+
62+
$this->addToAssertionCount(1);
63+
}
64+
5565
public function testIfAServiceDefinitionWithAnExpressionArgumentIsCorrectTheContainerWillBeCompiled()
5666
{
5767
if (!class_exists('Symfony\Component\DependencyInjection\ExpressionLanguage')) {

0 commit comments

Comments
 (0)