Browse Source

Try to replace the sleep by WaitUntil ...

master
Sébastien Lucas 8 years ago
parent
commit
900d110d15
1 changed files with 7 additions and 1 deletions
  1. +7
    -1
      test/Sauce.php

+ 7
- 1
test/Sauce.php View File

@@ -201,9 +201,15 @@ class Cops extends Sauce\Sausage\WebDriverTestCase
// Click on the cog to show the search
$cog = $this->byId ("searchImage");
$cog->click ();
sleep (1);
//sleep (1);

// Focus the input and type
$this->waitUntil(function () {
if ($this->byName ("query")) {
return true;
}
return null;
}, 1000);
$queryInput = $this->byName ("query");
$queryInput->click ();
$queryInput->value ($src);


Loading…
Cancel
Save