Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions Config/Processor/InheritanceProcessor.php
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ private static function checkTypeExists($name, array $configs, $child)
{
if (!isset($configs[$name])) {
throw new \InvalidArgumentException(sprintf(
'Type %s inherits by %s not found.',
'Type %s inherited by %s not found.',
json_encode($name),
json_encode($child)
));
Expand All @@ -142,9 +142,9 @@ private static function checkAllowedInheritsTypes($name, array $config, array $a
{
if (empty($config['decorator']) && isset($config['type']) && !in_array($config['type'], $allowedTypes)) {
throw new \InvalidArgumentException(sprintf(
'Type %s can\'t inherits %s because %s is not allowed type (%s).',
json_encode($name),
'Type %s can\'t inherit %s because its type (%s) is not allowed type (%s).',
json_encode($child),
json_encode($name),
json_encode($config['type']),
json_encode($allowedTypes)
));
Expand Down
4 changes: 2 additions & 2 deletions Tests/Config/Processor/InheritanceProcessorTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ class InheritanceProcessorTest extends TestCase

/**
* @expectedException \InvalidArgumentException
* @expectedExceptionMessage Type "toto" inherits by "bar" not found.
* @expectedExceptionMessage Type "toto" inherited by "bar" not found.
*/
public function testExtendsUnknownType()
{
Expand Down Expand Up @@ -53,7 +53,7 @@ public function testCircularExtendsType()

/**
* @expectedException \InvalidArgumentException
* @expectedExceptionMessage Type "toto" can't inherits "bar" because "enum" is not allowed type (["object","interface"]).
* @expectedExceptionMessage Type "bar" can't inherit "toto" because its type ("enum") is not allowed type (["object","interface"]).
*/
public function testNotAllowedType()
{
Expand Down