Questions tagged [mink]

Mink is an open source acceptance test framework for web applications, written in PHP 5.3.

460 questions
0
votes
0 answers

Creating new "press button" step

I need a help to create my own Behat step similar to "When I press ". I'm doing this, because original press method doesn't seem to work correctly. I want to call it "When I press submit button ..." So, this is the start of the FeatureContext.php's…
user1499804
  • 227
  • 2
  • 6
  • 11
0
votes
1 answer

Behat's "When I press..." doesn't work with Selenium 2.33

I need to make a test with logging in my local website. Here is Behat's test feature: Feature: test In order to log in As a test user I need to get positive results @javascript Scenario: Logging in using Behat Given I am on…
user1499804
  • 227
  • 2
  • 6
  • 11
0
votes
2 answers

How to specify this XPATH?

Given this is my DOM, and it doesn't belong to me so I may not modify it in any way, how do I select the correct "click here" link based on the product-id inner text? Note that there are 3 products in this code and the link can appear at any place…
Joel Joel Binks
  • 1,628
  • 5
  • 27
  • 47
0
votes
2 answers

cant write features in French in Behat

I am trying to write my features with a few words from French language, I have followed the behat tutorial and correctly added the comment #language: fr at the beginning of the file I am also saving the file in utf-8 format.... but behat still…
Taz
  • 173
  • 9
0
votes
1 answer

I have an error after having installed Behat + Mink by "pear"

I have installed Behat and Mink by pear commands and after running Behat using behat -h command, I got an error: "PHP Fatal error: Class 'Symfony\Component\Console\Helper\ProgressHelper' not found in …
user1499804
  • 227
  • 2
  • 6
  • 11
0
votes
1 answer

Javascript self invoking function issue (Behat/Mink/Sahi)

I'm currently at a loss to why this is occurring, but I wouldn't be surprised if I was either way off, or missing one tiny little thing. Here's my code: (function() { if (jQuery('section.news-feed ul li').text().length > 0) { var…
tinyBIGideas
  • 194
  • 4
  • 13
0
votes
1 answer

Behat/Mink - Test failing after search action taken

I am working on writing Behat tests for an old bojankity system written in PHP. It seems to work for a number of test cases. However I am running into a strange problem. I have Behat logging in and navigating to the search form page. Then it fills…
Patrick
  • 3,302
  • 4
  • 28
  • 47
0
votes
1 answer

Installing behat with mink on windows using composer

I am trying to install mink/behat on windows machine using composer by following the help given on behat page. http://docs.behat.org/cookbook/behat_and_mink.html. But when I run php composer.phar install then I get the error But I have…
waqas
  • 1,115
  • 5
  • 19
  • 32
0
votes
2 answers

cannot run Selenium tests on some browsers

i have tests made with Mink using Selenium 2 driver. everything is working OK under Windows 7 with Firefox, Chrome and IE and Ubuntu 12.10 with Firefox. the problems are: when i try to run test on Opera (Windows 7) it launches but it cannot find…
Axarsu
  • 447
  • 1
  • 5
  • 10
0
votes
1 answer

Accessing Symfony 2' s DI container from mink

I'm using behat with the mink extension to run fonctionnal tests. I've got a FeatureContext, extending the MinkContext. I'm trying to pass custom parameters to my context, but I'm not really sure how. My idea was to put them in the behat.yml and…
David
  • 33,444
  • 11
  • 80
  • 118
0
votes
1 answer

Behat follow links with html in it

I have a response similar to 1 widget and a feature like Feature: My feature Scenario: My Scenario Given I am on the homepage Then I should see a "1 widget" This will obviously fail because of the span tag.…
Michael Smith
  • 409
  • 3
  • 6
0
votes
1 answer

Testing Remember me functionality with Behat/Mink

I am trying to test a remember me functionality with Behat and Mink in a Symfony2 project. However, my approach is not working. I tried the following: #behat.yml Scenario: Checking Remember me Given I am on "/" When I fill in "username" with…
sprain
  • 7,552
  • 6
  • 35
  • 49
0
votes
3 answers

Call to a member function getSession() on a non-object in vendor/behat/mink-extension/src/Behat/MinkExtension/Context/RawMinkContext.php on line 81

I get this error when trying to run my behat tests from the command line. The full output of the error looks like this: $ behat Feature: View a list of current custom tariffs In order to provide custom call…
Stuart Grimshaw
  • 1,541
  • 1
  • 18
  • 41
0
votes
1 answer

Sahi + PhantomJS fails when testing local PHP web app with behat

I'm having an issue testing a locally hosted web application with a behat+sahi+phantomjs set up. I have run the full suite with just behat+sahi+chrome which works fine I have also tested a small sample behat test against a live stie that works…
user945747
0
votes
1 answer

Behat Mink: send a key press to the active element

I'm trying to test whether navigating with the tab key works on my system. Here is my code: define('TAB_CHARCODE', 9); define('NO_MODIFIER', ''); // .... $this->getSession()->getPage()->find('css', ':focus')->keyPress(TAB_CHARCODE,…
alberto56
  • 2,997
  • 3
  • 28
  • 47