minkphp / MinkGoutteDriver

Goutte driver for Mink framework
MIT License
299 stars 52 forks source link

verify: false in Guzzle parameters no longer works with Goutte 3 #68

Closed clemf closed 3 years ago

clemf commented 9 years ago

With the addition of Goutte 3 support in version 1.2.0, my scenarios are now throwing SSL errors even though I have the recommended settings from the Mink Extension documentation:

default:
    extensions:
        Behat\MinkExtension:
            sessions:
                my_session:
                    goutte:
                        guzzle_parameters:
                            verify: false

If I downgrade to version 1.1.0 (and therefore to Goutte 2 & Guzzle 5), my scenarios work again and the SSL cert is ignored as expected. I'm not exactly sure if the problem is in the driver, or something in Goutte or Guzzle but my problem was definitely triggered by the driver's update to 1.2.0.

stof commented 9 years ago

Well, the internal structure of the guzzle parameters depend on the Guzzle version. The MinkExtension passes them to Guzzle. And this is not an issue for the MinkGoutteDriver itself (which does not accept any Goutte or Guzzle configuration, but a Goutte client instance).

Note that the 1.2 version of the driver can totally be used with Goutte 2. It supports Goutte 1, 2 and 3 (Composer will use the higher version of Goutte compatible with your PHP version, unless you put a requirement to restrict it).

clemf commented 9 years ago

I can confirm that my Behat scenarios work fine with MinkGoutteDriver v1.2.0, Goutte 2, and Guzzle 5. I'd like to figure out how to get it working with the newer versions. According to the current Guzzle docs, I'm using the right parameters. I assume somehow the configuration isn't being passed through properly? Should I post an issue with Behat instead?

susa-ostec commented 9 years ago

@clemf: Did you find any solution? Unfortunatly I've got the same problem as you. Looks like default parameters are not overwritten by behat.yml... :(

clemf commented 9 years ago

@susa-ostec I haven't had time to look into it, I'm just sticking with the older versions for now. I think this issue should probably go on the main Behat repository.

epfremmer commented 8 years ago

Suggested #71 until such time as behat/mink-extension can be updated with new goutteFactory buildGuzzle6Client method.