Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

PHPUnit tests don't detect deprecations appear during container initialization #24767

Copy link
Copy link
Closed
@ossinkine

Description

@ossinkine
Issue body actions
Q A
Bug report? yes
Feature request? no
BC Break report? no
RFC? no
Symfony version 3.3

For example YAML configuration contains deprecations, f.e. config_dev.yml contains non-escaped expressions:

monolog:
    handlers:
        main:
            type: stream
            path: %kernel.logs_dir%/%kernel.environment%.log
            level: debug
            channels: [!event]
        console:
            type: console
            process_psr_3_messages: false
            channels: [!event, !doctrine, !console]

In the web panel you can see notices like Using the unquoted scalar value "!event" is deprecated since version 3.3 and will be considered as a tagged value in 4.0.. But when you run functional tests there are no notices, tests are passed. You can only see serialized deprecations in the var/cache/test/appTestDebugProjectContainerDeprecations.log. It happens because errors are caught at https://github.com/symfony/symfony/blob/master/src/Symfony/Component/HttpKernel/Kernel.php#L464 and previous PHPUnit Bridge handler is not called.

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

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.