Skip to content

[FrameworkBundle][BC Break ?] Accessing static property $client in classes extending WebTestCase #31653

Closed
@gnutix

Description

@gnutix

Symfony version(s) affected: 4.3.0-BETA2

Description
In symfony/framework-bundle@58e572e, protected static $client; was added to \Symfony\Bundle\FrameworkBundle\Test\WebTestCase.

I've upgraded my project to Symfony 4.3.0-BETA2 and had to fix my test suite and that of already multiple different libraries because it used $this->client to access the client (which is now triggering errors like Accessing static property Craue\FormFlowBundle\Tests\RevalidatePreviousStepsFlowTest::$client as non static, when it used to "work" before).

How to reproduce
Clone https://github.com/craue/CraueFormFlowBundle on branch "autoconfiguration" and run composer install && vendor/bin/phpunit.

Possible Solution
Either revert the addition, or write documentation as I think it's a BC break of sorts.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions