minkphp / MinkSahiDriver

[DEPRECATED] Sahi.JS driver for Mink framework
MIT License
13 stars 8 forks source link

Sahi time limit reached #17

Open gherrink opened 10 years ago

gherrink commented 10 years ago

Hey I'm using Behat with Mink and Sahi. My Web-Application is running local with apache and XAMPP.

I just tryed to get the hole page with

$driver = new \Behat\Mink\Driver\SahiDriver('firefox',
        new \Behat\SahiClient\Client(
            new \Behat\SahiClient\Connection(null, 'localhost', 9999)
)
);
$session = new \Behat\Mink\Session($driver);
$session->start();
$session->visit('https://localhost/CMS/index.php/login/login');
echo $session->getPage()->getContent();

and get this error: Command execution time limit reached: _sahi.setServerVarPlain('___lastValue___527a9575b8270', document.getElementsByTagName("html")[0].innerHTML)

After I deactivated my https connection on my Side i was able to get the page. I think Sahi don't like the Certificate or something like this.

Hope this will help someone and someone cane give me an advice how I'm able to handle a https connection.

ramonasuciu commented 10 years ago

The same happens for me as well, and I am not using https connection. Whenever I try to match the url or find some text in a certain page in my test app, I receive the "Command execution time limit reached: _sahi.setServerVarPlain('...)" error.

Does anyone have any updates on it?

aik099 commented 10 years ago

But how this is a Mink problem?

I think it's a problem with Sahi in general that it doesn't like https:// connections with invalid certificates.

AbijeetP commented 10 years ago

Would like to find a solution to this

onchainguy-btc commented 10 years ago

Still no solution for this?

aik099 commented 10 years ago

It's not a Mink's Driver's fault but Sahi one. You'd better post to their issue tracker.

andrerom commented 9 years ago

Actually it is coming from Behat\SahiClient\Connection->executeStep():

        $limit = $limit ?: $this->limit;
        $check = 'false';
        while ('true' !== $check) {
            usleep(100000);
            if (--$limit <= 0) {
                throw new Exception\ConnectionException(
                    'Command execution time limit reached: `' . $step . '`'
                );
            }

In our case we have a step that takes very long time by design (downloads packages from the net), so if that is your case trying to configure the limit to be higher than 600 might help using:

default:
    extensions:
        Behat\MinkExtension:
            sahi:
                limit: 900