Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8734651
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T09:53:09+00:00 2026-06-13T09:53:09+00:00

I’m having some problems with Behat and Mink. The driver used is Goutte. I’m

  • 0

I’m having some problems with Behat and Mink. The driver used is Goutte. I’m trying to test my Symfony 2.1 application.

My behat.yml:

default:
extensions:
    Behat\Symfony2Extension\Extension:
        mink_driver: true
    Behat\MinkExtension\Extension:
        base_url: 'http://localhost/project/web/app_dev.php'
        goutte: ~

My test.feature:

Feature: Test
   In order to log-in
   As a user
   I need to be able to use the login-form

   Scenario: Logging in
       Given I am on "/login"
       When I fill in "username" with "admin"
       And I fill in "password" with "password"
       And I press "_submit"
       Then show last response
       Then I should see "Hello"

When I try to execute the tests (on Windows 7):

bin\behat @MyTestBundle

The tests stop at

And I press “_submit”

With this error:

Current URI must be an absolute URL ("/app_dev.php").

I’ve already tried almost all possible base_url paths and I didn’t managed to get it work.

Do You have any idea’s how to fix this problem?

The form I try to submit:

<form action="/app_dev.php/login_check" class="form-horizontal" method="post">
    <fieldset>
        <div class="control-group">
            <label class="control-label" for="username">Nazwa użytkownika:</label>

            <div class="controls"><input type="text" id="username" name="_username" value=""/></div>
        </div>

        <div class="control-group">
            <label for="password" class="control-label">Hasło:</label>

            <div class="controls"><input type="password" id="password" name="_password"/></div>
        </div>

        <div class="control-group">
            <div class="controls">
                <label for="remember_me" class="checkbox">
                    <input type="checkbox" id="remember_me" name="_remember_me" value="on"/>Nie wylogowuj mnie
                </label>
            </div>

        </div>
        <div class="form-actions">
            <input type="submit" class="btn-primary" id="_submit" name="_submit"
                   value="Zaloguj"/>
            <a href="/app_dev.php/register/" class="btn btn-success">Rejestracja</a>
        </div>
    </fieldset>
</form>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T09:53:10+00:00Added an answer on June 13, 2026 at 9:53 am

    I’ve found a solution to my problem today.

    Indeed the problem Was in the path function. The path function should be replaced with the twig url function.

    What’s interesting: changing the function to url in the form action attribute won’t help. In my base layout i had:

    <base href="{{ path('_default')}}"/>
    

    This one line of code caused the problem, it should be:

    <base href="{{ url('_default')}}"/>
    

    After this change the test works as expected.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

link Im having trouble converting the html entites into html characters, (&# 8217;) i
I have just tried to save a simple *.rtf file with some websites and
For some reason, after submitting a string like this Jack’s Spindle from a text
I am trying to understand how to use SyndicationItem to display feed which is
I used javascript for loading a picture on my website depending on which small
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
I am trying to render a haml file in a javascript response like so:
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
We're building an app, our first using Rails 3, and we're having to build
I'm trying to select an H1 element which is the second-child in its group

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.