Skip to content

[DependencyInjection] Possible tiny bug with test #35505

@signor-pedro

Description

@signor-pedro

Symfony version(s) affected: 5.0

Description
There is a test called testThrowsException... but it does not expectException.

https://github.com/symfony/dependency-injection/blob/0f495ead513e83d01e4363995c1d6984e2a0f9ed/Tests/ContainerBuilderTest.php#L1100

Either the test is misnamed (should be rather testNoExceptionWhenAddServiceOnACompiledContainer) or it might be a false-positive and the exception check was forgotten (improbable).

Possible Solution
Rename the test or add the necessary check.

I assume this is a typo so I renamed the test in my PR.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions