Behat/MinkBrowserKitDriver — pull request #24 by arcturial (2013-10-30 19:11:01+00:00)
Title: GetCurrentUrl() return null instead of fatal error

Related to https://github.com/Behat/MinkBrowserKitDriver/pull/17. When a user calls `getCurrentUrl()` without having made a request yet. The function throws a fatal error complaining that `getRequest()` returns a non-object.

How To Replicate:
- Configure an @AfterStep event that prints out $this->getSession()->getCurrentUrl()
- Run the following scenario.

Scenario:
Then print current URL

I know you wouldn't expect it to work since you haven't navigated anymore. However, I think it should still be handled "gracefully" instead of breaking execution...as there are legitimate cases for wanting to retrieve the current URL without knowing if any requests have been executed yet.