Commit ddbb2c79 authored by webchick's avatar webchick

Issue #2433009 by hussainweb, grom358, neclimdul, daffie, larowlan, alexpott,...

Issue #2433009 by hussainweb, grom358, neclimdul, daffie, larowlan, alexpott, pcambra, benjy, jibran, phenaproxima, moshe weitzman, nick_schuch: Add Mink, with Goutte driver, to core
parent 3eafd2d1
......@@ -27,7 +27,10 @@
"zendframework/zend-feed": "2.3.*",
"mikey179/vfsStream": "1.*",
"stack/builder": "1.0.*",
"egulias/email-validator": "1.2.*"
"egulias/email-validator": "1.2.*",
"behat/mink": "~1.6",
"behat/mink-goutte-driver": "~1.1",
"fabpot/goutte": "dev-master"
},
"autoload": {
"psr-4": {
......
......@@ -4,8 +4,170 @@
"Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
"This file is @generated automatically"
],
"hash": "c977649e8e1a8b93301fa83283672a06",
"hash": "71958cc676a2780e738e9a7d95a3b78b",
"packages": [
{
"name": "behat/mink",
"version": "v1.6.1",
"source": {
"type": "git",
"url": "https://github.com/minkphp/Mink.git",
"reference": "8b68523a339ec991bcd638b39dc8f04f808da88a"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/minkphp/Mink/zipball/8b68523a339ec991bcd638b39dc8f04f808da88a",
"reference": "8b68523a339ec991bcd638b39dc8f04f808da88a",
"shasum": ""
},
"require": {
"php": ">=5.3.1",
"symfony/css-selector": "~2.0"
},
"suggest": {
"behat/mink-browserkit-driver": "extremely fast headless driver for Symfony\\Kernel-based apps (Sf2, Silex)",
"behat/mink-goutte-driver": "fast headless driver for any app without JS emulation",
"behat/mink-selenium2-driver": "slow, but JS-enabled driver for any app (requires Selenium2)",
"behat/mink-zombie-driver": "fast and JS-enabled headless driver for any app (requires node.js)"
},
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "1.6.x-dev"
}
},
"autoload": {
"psr-4": {
"Behat\\Mink\\": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Konstantin Kudryashov",
"email": "ever.zet@gmail.com",
"homepage": "http://everzet.com"
}
],
"description": "Browser controller/emulator abstraction for PHP",
"homepage": "http://mink.behat.org/",
"keywords": [
"browser",
"testing",
"web"
],
"time": "2015-02-04 17:02:06"
},
{
"name": "behat/mink-browserkit-driver",
"version": "v1.2.0",
"source": {
"type": "git",
"url": "https://github.com/minkphp/MinkBrowserKitDriver.git",
"reference": "aed8f4a596b79014a75254c3e337511c33e38cbd"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/minkphp/MinkBrowserKitDriver/zipball/aed8f4a596b79014a75254c3e337511c33e38cbd",
"reference": "aed8f4a596b79014a75254c3e337511c33e38cbd",
"shasum": ""
},
"require": {
"behat/mink": "~1.6@dev",
"php": ">=5.3.1",
"symfony/browser-kit": "~2.0",
"symfony/dom-crawler": "~2.0"
},
"require-dev": {
"silex/silex": "~1.2"
},
"type": "mink-driver",
"extra": {
"branch-alias": {
"dev-master": "1.2.x-dev"
}
},
"autoload": {
"psr-0": {
"Behat\\Mink\\Driver": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Konstantin Kudryashov",
"email": "ever.zet@gmail.com",
"homepage": "http://everzet.com"
}
],
"description": "Symfony2 BrowserKit driver for Mink framework",
"homepage": "http://mink.behat.org/",
"keywords": [
"Mink",
"Symfony2",
"browser",
"testing"
],
"time": "2014-09-26 11:35:19"
},
{
"name": "behat/mink-goutte-driver",
"version": "v1.1.0",
"source": {
"type": "git",
"url": "https://github.com/minkphp/MinkGoutteDriver.git",
"reference": "2bf327b4166694ecaa8ae7f956cb6ae252ecf03e"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/minkphp/MinkGoutteDriver/zipball/2bf327b4166694ecaa8ae7f956cb6ae252ecf03e",
"reference": "2bf327b4166694ecaa8ae7f956cb6ae252ecf03e",
"shasum": ""
},
"require": {
"behat/mink": "~1.6@dev",
"behat/mink-browserkit-driver": "~1.2@dev",
"fabpot/goutte": "~1.0.4|~2.0",
"php": ">=5.3.1"
},
"type": "mink-driver",
"extra": {
"branch-alias": {
"dev-master": "1.1.x-dev"
}
},
"autoload": {
"psr-0": {
"Behat\\Mink\\Driver": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Konstantin Kudryashov",
"email": "ever.zet@gmail.com",
"homepage": "http://everzet.com"
}
],
"description": "Goutte driver for Mink framework",
"homepage": "http://mink.behat.org/",
"keywords": [
"browser",
"goutte",
"headless",
"testing"
],
"time": "2014-10-09 09:21:12"
},
{
"name": "doctrine/annotations",
"version": "v1.2.1",
......@@ -570,6 +732,55 @@
],
"time": "2014-11-06 08:59:44"
},
{
"name": "fabpot/goutte",
"version": "dev-master",
"source": {
"type": "git",
"url": "https://github.com/FriendsOfPHP/Goutte.git",
"reference": "65ab61eae03d670b93a9044ad2328eb81aa1bde5"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/FriendsOfPHP/Goutte/zipball/65ab61eae03d670b93a9044ad2328eb81aa1bde5",
"reference": "65ab61eae03d670b93a9044ad2328eb81aa1bde5",
"shasum": ""
},
"require": {
"guzzlehttp/guzzle": ">=4,<6",
"php": ">=5.4.0",
"symfony/browser-kit": "~2.1",
"symfony/css-selector": "~2.1",
"symfony/dom-crawler": "~2.1"
},
"type": "application",
"extra": {
"branch-alias": {
"dev-master": "2.0-dev"
}
},
"autoload": {
"psr-4": {
"Goutte\\": "Goutte"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com"
}
],
"description": "A simple PHP Web Scraper",
"homepage": "https://github.com/FriendsOfPHP/Goutte",
"keywords": [
"scraper"
],
"time": "2014-11-28 09:48:17"
},
{
"name": "guzzlehttp/guzzle",
"version": "5.0.3",
......@@ -1693,6 +1904,61 @@
],
"time": "2014-10-20 20:55:17"
},
{
"name": "symfony/browser-kit",
"version": "v2.6.4",
"target-dir": "Symfony/Component/BrowserKit",
"source": {
"type": "git",
"url": "https://github.com/symfony/BrowserKit.git",
"reference": "2ecec44ed5047020c65dd6e4a4b2f3cf13ae3c04"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/BrowserKit/zipball/2ecec44ed5047020c65dd6e4a4b2f3cf13ae3c04",
"reference": "2ecec44ed5047020c65dd6e4a4b2f3cf13ae3c04",
"shasum": ""
},
"require": {
"php": ">=5.3.3",
"symfony/dom-crawler": "~2.0,>=2.0.5"
},
"require-dev": {
"symfony/css-selector": "~2.0,>=2.0.5",
"symfony/process": "~2.0,>=2.0.5"
},
"suggest": {
"symfony/process": ""
},
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "2.6-dev"
}
},
"autoload": {
"psr-0": {
"Symfony\\Component\\BrowserKit\\": ""
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Symfony Community",
"homepage": "http://symfony.com/contributors"
},
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com"
}
],
"description": "Symfony BrowserKit Component",
"homepage": "http://symfony.com",
"time": "2015-01-03 08:01:59"
},
{
"name": "symfony/class-loader",
"version": "v2.6.4",
......@@ -1914,6 +2180,59 @@
"homepage": "http://symfony.com",
"time": "2015-01-25 04:39:26"
},
{
"name": "symfony/dom-crawler",
"version": "v2.6.4",
"target-dir": "Symfony/Component/DomCrawler",
"source": {
"type": "git",
"url": "https://github.com/symfony/DomCrawler.git",
"reference": "26a9eb302decd828990e1015afaa11b78b016073"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/DomCrawler/zipball/26a9eb302decd828990e1015afaa11b78b016073",
"reference": "26a9eb302decd828990e1015afaa11b78b016073",
"shasum": ""
},
"require": {
"php": ">=5.3.3"
},
"require-dev": {
"symfony/css-selector": "~2.3"
},
"suggest": {
"symfony/css-selector": ""
},
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "2.6-dev"
}
},
"autoload": {
"psr-0": {
"Symfony\\Component\\DomCrawler\\": ""
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Symfony Community",
"homepage": "http://symfony.com/contributors"
},
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com"
}
],
"description": "Symfony DomCrawler Component",
"homepage": "http://symfony.com",
"time": "2015-01-03 08:01:59"
},
{
"name": "symfony/event-dispatcher",
"version": "v2.6.4",
......@@ -2651,7 +2970,9 @@
"packages-dev": [],
"aliases": [],
"minimum-stability": "stable",
"stability-flags": [],
"stability-flags": {
"fabpot/goutte": 20
},
"prefer-stable": false,
"prefer-lowest": false,
"platform": {
......
language: php
php: [5.3, 5.4, 5.5, 5.6, hhvm]
matrix:
include:
- php: 5.5
env: SYMFONY_VERSION='2.3.*'
- php: 5.5
env: SYMFONY_VERSION='2.5.*@dev'
before_script:
- sh -c 'if [ "$SYMFONY_VERSION" != "" ]; then composer require -n --no-update symfony/symfony=$SYMFONY_VERSION; fi;'
- composer install -n --prefer-source
script: phpunit -v --coverage-clover=coverage.clover
after_script:
- wget https://scrutinizer-ci.com/ocular.phar
- php ocular.phar code-coverage:upload --format=php-clover coverage.clover
1.2.0 / 2014-09-26
==================
BC break:
* Changed the behavior of `getValue` for checkboxes according to the BC break in Mink 1.6
New features:
* Implemented `getOuterHtml`
* Added the support of manipulating forms without submit buttons
* Added support of any request headers instead of supporting only a few hardcoded ones
* Added support of any BrowserKit client using `filterResponse` when using BrowserKit 2.3+
* Added the support of reset buttons
* Implemented `submitForm`
* Implemented `isSelected`
Bug fixes:
* Fixed the support of options without value attribute in `isSelected` and `getValue`
* Added the support of radio buttons in `isChecked`
* Fixed the submission of empty textarea fields
* Refactored the handling of request headers to ensure they are reset when resetting the driver
* Fixed the handling of buttons to submit only for submit buttons rather than all buttons
* Fixed the code to throw exceptions rather than triggering a fatal error for invalid usages of the driver
* Fixed the removal of cookies
* Fixed the submission of form fields with same name and without id
* Fixed `getAttribute` to return `null` for missing attributes rather than an empty string
Testing:
* Updated the testsuite to use the new Mink 1.6 driver testsuite
* Added testing on HHVM
Copyright (c) 2012-2013 Konstantin Kudryashov <ever.zet@gmail.com>
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
files (the "Software"), to deal in the Software without
restriction, including without limitation the rights to use,
copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.
Mink BrowserKit Driver
======================
[![Latest Stable Version](https://poser.pugx.org/behat/mink-browserkit-driver/v/stable.png)](https://packagist.org/packages/behat/mink-browserkit-driver)
[![Latest Unstable Version](https://poser.pugx.org/behat/mink-browserkit-driver/v/unstable.svg)](https://packagist.org/packages/behat/mink-browserkit-driver)
[![Total Downloads](https://poser.pugx.org/behat/mink-browserkit-driver/downloads.png)](https://packagist.org/packages/behat/mink-browserkit-driver)
[![Build Status](https://travis-ci.org/Behat/MinkBrowserKitDriver.svg?branch=master)](https://travis-ci.org/Behat/MinkBrowserKitDriver)
[![Scrutinizer Quality Score](https://scrutinizer-ci.com/g/Behat/MinkBrowserKitDriver/badges/quality-score.png?s=0443d284940e099ea560eb39b6b2fcdc5d4e7f29)](https://scrutinizer-ci.com/g/Behat/MinkBrowserKitDriver/)
[![Code Coverage](https://scrutinizer-ci.com/g/Behat/MinkBrowserKitDriver/badges/coverage.png?s=48960c4495488ab0b7d310b62322f017497f5bfa)](https://scrutinizer-ci.com/g/Behat/MinkBrowserKitDriver/)
[![License](https://poser.pugx.org/behat/mink-browserkit-driver/license.svg)](https://packagist.org/packages/behat/mink-browserkit-driver)
Usage Example
-------------
``` php
<?php
use Behat\Mink\Mink,
Behat\Mink\Session,
Behat\Mink\Driver\BrowserKitDriver;
use Symfony\Component\HttpKernel\Client;
$app = require_once(__DIR__.'/app.php'); // Silex app
$mink = new Mink(array(
'silex' => new Session(new BrowserKitDriver(new Client($app))),
));
$mink->getSession('silex')->getPage()->findLink('Chat')->click();
```
Installation
------------
``` json
{
"require": {
"behat/mink": "~1.5",
"behat/mink-browserkit-driver": "~1.1"
}
}
```
``` bash
$> curl -sS https://getcomposer.org/installer | php
$> php composer.phar install
```
Maintainers
-----------
* Konstantin Kudryashov [everzet](http://github.com/everzet)
* Other [awesome developers](https://github.com/Behat/MinkBrowserKitDriver/graphs/contributors)
{
"name": "behat/mink-browserkit-driver",
"description": "Symfony2 BrowserKit driver for Mink framework",
"keywords": ["Symfony2", "Mink", "testing", "browser"],
"homepage": "http://mink.behat.org/",
"type": "mink-driver",
"license": "MIT",
"authors": [
{
"name": "Konstantin Kudryashov",
"email": "ever.zet@gmail.com",
"homepage": "http://everzet.com"
}
],
"require": {
"php": ">=5.3.1",
"behat/mink": "~1.6@dev",
"symfony/browser-kit": "~2.0",
"symfony/dom-crawler": "~2.0"
},
"require-dev": {
"silex/silex": "~1.2"
},
"autoload": {
"psr-0": {
"Behat\\Mink\\Driver": "src/"
}
},
"autoload-dev": {
"psr-4": {
"Behat\\Mink\\Tests\\Driver\\": "tests"