mirror of
https://github.com/silverstripe/silverstripe-installer
synced 2024-09-30 05:09:10 +02:00
Merge pull request #24 from chillu/pulls/behat
Added 'phing behat' command
This commit is contained in:
commit
0f28a3d456
20
behat.yml
Normal file
20
behat.yml
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
default:
|
||||||
|
extensions:
|
||||||
|
|
||||||
|
SilverStripe\BehatExtension\Extension:
|
||||||
|
framework_path: framework
|
||||||
|
|
||||||
|
Behat\MinkExtension\Extension:
|
||||||
|
# Adjust this to your own website URL.
|
||||||
|
# Uncomment, or set through environment variable:
|
||||||
|
# > export BEHAT_PARAMS="extensions[Behat\MinkExtension\Extension][base_url]=http://localhost/"
|
||||||
|
#
|
||||||
|
# base_url: http://localhost/
|
||||||
|
|
||||||
|
# TODO Dynamically set through LocatorProcessor
|
||||||
|
files_path: %behat.paths.base%/framework/tests/behat/features/files/
|
||||||
|
default_session: selenium2
|
||||||
|
javascript_session: selenium2
|
||||||
|
goutte: ~
|
||||||
|
selenium2:
|
||||||
|
browser: firefox
|
27
build.xml
27
build.xml
@ -133,6 +133,27 @@ Options:
|
|||||||
<exec command="${phpunit_bin}" checkreturn="true" passthru="true" />
|
<exec command="${phpunit_bin}" checkreturn="true" passthru="true" />
|
||||||
</target>
|
</target>
|
||||||
|
|
||||||
|
<target name="behat" if="basedir"
|
||||||
|
description="Runs behaviour tests through Behat, on the 'framework' and 'cms' modules (if available). Requires phpunit, composer and behat.">
|
||||||
|
|
||||||
|
<if>
|
||||||
|
<available file="${basedir}/framework/" type="dir" />
|
||||||
|
<then>
|
||||||
|
<echo msg="Testing 'framework' module" />
|
||||||
|
<exec command="vendor/bin/behat @framework" checkreturn="true" passthru="true" />
|
||||||
|
</then>
|
||||||
|
</if>
|
||||||
|
|
||||||
|
<if>
|
||||||
|
<available file="${basedir}/cms/" type="dir" />
|
||||||
|
<then>
|
||||||
|
<echo msg="Testing 'cms' module" />
|
||||||
|
<exec command="vendor/bin/behat @cms" checkreturn="true" passthru="true" />
|
||||||
|
</then>
|
||||||
|
</if>
|
||||||
|
|
||||||
|
</target>
|
||||||
|
|
||||||
<target name="tag" if="basedir"
|
<target name="tag" if="basedir"
|
||||||
description="Creates a new git tag in all the nested working copies (optionally pushes the created tag)"
|
description="Creates a new git tag in all the nested working copies (optionally pushes the created tag)"
|
||||||
depends="_gitRepositories,_gitBinary">
|
depends="_gitRepositories,_gitBinary">
|
||||||
@ -247,7 +268,8 @@ Options:
|
|||||||
<exclude name="_ss_environment.php" />
|
<exclude name="_ss_environment.php" />
|
||||||
<exclude name="*.tar.gz" />
|
<exclude name="*.tar.gz" />
|
||||||
<exclude name="*.zip" />
|
<exclude name="*.zip" />
|
||||||
|
<exclude name="behat.yml" />
|
||||||
|
<exclude name="composer.*" />
|
||||||
</fileset>
|
</fileset>
|
||||||
<fileset dir="${basedir}">
|
<fileset dir="${basedir}">
|
||||||
<include name="assets/Uploads" />
|
<include name="assets/Uploads" />
|
||||||
@ -278,7 +300,8 @@ Options:
|
|||||||
<exclude name="_ss_environment.php" />
|
<exclude name="_ss_environment.php" />
|
||||||
<exclude name="*.tar.gz" />
|
<exclude name="*.tar.gz" />
|
||||||
<exclude name="*.zip" />
|
<exclude name="*.zip" />
|
||||||
|
<exclude name="behat.yml" />
|
||||||
|
<exclude name="composer.*" />
|
||||||
<exclude name="cms/**" />
|
<exclude name="cms/**" />
|
||||||
</fileset>
|
</fileset>
|
||||||
<fileset dir="${basedir}">
|
<fileset dir="${basedir}">
|
||||||
|
Loading…
Reference in New Issue
Block a user