Behat / MinkExtension

Mink extension (tight integration and configuration) for Behat
MIT License
636 stars 279 forks source link

not able to run feature in saucelab account. #215

Open ghost opened 9 years ago

ghost commented 9 years ago

image

I am trying to run feature file using above YAML file as config and below is my comopser.json.

{
    "require": {
        "behat/mink-extension": "2.0.1",
        "behat/mink-selenium2-driver": "1.2.0",
        "behat/mink-browserkit-driver": "1.2.0",
        "behat/mink-goutte-driver": " 1.1.0",
        "drupal/drupal-extension": "*",
        "sauce/sausage": "=v0.5",
        "sauce/connect": "3.0"
    },
    "config": {
        "bin-dir": "bin/"
    }
}

command used : bin\behat.bat -c=behat.yml features\rml\registration\ -s qa But I could not see any execution in sauce lab account. is anything wrong in YAML ?

stof commented 9 years ago

The YAML configuration looks good to me.

ghost commented 9 years ago

what could be issue then ? I am not using sauce-connect. I am trying this behat 3 and mink extension 2.0 because I was unable to use max-duration capability with behat 2.5 and mink extension 1.1

Shine-neko commented 8 years ago

@stof @nirbhaypatil SauceLabs do not support https://github.com/Behat/MinkExtension/blob/master/src/Behat/MinkExtension/ServiceContainer/Driver/SauceLabsFactory.php#L68-L71 If i delete option it works

jenschude commented 8 years ago

Or just add to the behat.yml

      sauce_labs:
        capabilities:
          custom-data:
            foo: bar

Worked for me too.

jenschude commented 8 years ago

Investigated a little bit what actually happens and printed out what URL is used for the webDriver. As you can see the first instance is the default URL. Then when the scenarios are starting the correct URL is used. But with the first call (i follow) which really executes a request by SauceLabs the webDriver is instantiated with HTTP://. When adding the custom-data to the configuration the webDriver is instantiated correctly.

$ vendor/bin/behat -p sauce
string(28) "http://localhost:4444/wd/hub"
string(81) "username:access_key@ondemand.saucelabs.com/wd/hub"
Feature: Product Overview Page

  Scenario: open category                              
    Given I go to "/en/home"  
      │ string(96) "HTTP://username:access_key@ondemand.saucelabs.com/wd/hub/session"
      │
    When I follow "plus content"                       
      Link with id|title|alt|text "plus content" not found. 
    Then I should be on "/en/new"                     
    And the ".breadcrumb" element should contain "New"