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

[BrowserKit] BC-break since Client has been renamed to Browser #31039

Copy link
Copy link
Closed
@Devristo

Description

@Devristo
Issue body actions

Symfony version(s) affected: 4.3.x-dev

Description
Since #30541 the inheritance hierarchy of \Symfony\Component\BrowserKit\Client has changed. Notably the test.client no longer is an instance of \Symfony\Component\BrowserKit\Client.

This breaks breaks at least https://github.com/FriendsOfBehat/SymfonyExtension and https://github.com/minkphp/MinkBrowserKitDriver and most probably other bundles using test.client.

How to reproduce

On Symfony 4.2 the following test case succeeds, on the master (4.3) branch this fails:

class TestClientTest extends \Symfony\Bundle\FrameworkBundle\Test\WebTestCase {
    public function testIsAClient()
    {
        $browser = static::createClient();
        $this->assertInstanceOf(\Symfony\Component\BrowserKit\Client::class, $browser);
    }
}

Possible Solution
Use a class_alias solution as described in #30541.

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.