-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add more test scenarios giving g1a/composer-test-scenarios a try
- Loading branch information
1 parent
44ba5f7
commit ccc934c
Showing
8 changed files
with
236 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
#!/bin/bash | ||
|
||
SCENARIO=$1 | ||
DEPENDENCIES=${2-install} | ||
|
||
# Convert the aliases 'highest', 'lowest' and 'lock' to | ||
# the corresponding composer update command to run. | ||
case $DEPENDENCIES in | ||
highest) | ||
UPDATE_COMMAND=update | ||
;; | ||
lowest) | ||
UPDATE_COMMAND='update --prefer-lowest' | ||
;; | ||
lock|default|"") | ||
UPDATE_COMMAND='' | ||
;; | ||
esac | ||
|
||
original_name=scenarios | ||
recommended_name=".scenarios.lock" | ||
|
||
base="$original_name" | ||
if [ -d "$recommended_name" ] ; then | ||
base="$recommended_name" | ||
fi | ||
|
||
# If scenario is not specified, install the lockfile at | ||
# the root of the project. | ||
dir="$base/${SCENARIO}" | ||
if [ -z "$SCENARIO" ] || [ "$SCENARIO" == "default" ] ; then | ||
SCENARIO=default | ||
dir=. | ||
fi | ||
|
||
# Test to make sure that the selected scenario exists. | ||
if [ ! -d "$dir" ] ; then | ||
echo "Requested scenario '${SCENARIO}' does not exist." | ||
exit 1 | ||
fi | ||
|
||
echo | ||
echo "::" | ||
echo ":: Switch to ${SCENARIO} scenario" | ||
echo "::" | ||
echo | ||
|
||
set -ex | ||
|
||
composer -n validate --working-dir=$dir --no-check-all --ansi | ||
|
||
if [ ! -z "$UPDATE_COMMAND" ] ; then | ||
composer -n --working-dir=$dir ${UPDATE_COMMAND} --prefer-dist --no-scripts | ||
fi | ||
composer -n --working-dir=$dir install --prefer-dist | ||
|
||
# If called from a CI context, print out some extra information about | ||
# what we just installed. | ||
if [[ -n "$CI" ]] ; then | ||
composer -n --working-dir=$dir info | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
vendor |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
{ | ||
"name": "robertfausk/behat-panther-extension", | ||
"type": "behat-extension", | ||
"description": "Symfony Panther extension for Behat", | ||
"keywords": [ | ||
"behat", | ||
"symfony", | ||
"panther", | ||
"web", | ||
"test", | ||
"browser", | ||
"gui" | ||
], | ||
"license": "MIT", | ||
"authors": [ | ||
{ | ||
"name": "Robert Freigang", | ||
"email": "[email protected]" | ||
} | ||
], | ||
"require": { | ||
"symfony/config": "^3.4", | ||
"php": ">=7.1", | ||
"behat/behat": "^3.0.5", | ||
"behat/mink-extension": "^2.0", | ||
"robertfausk/mink-panther-driver": "^1.0" | ||
}, | ||
"require-dev": { | ||
"phpunit/phpunit": "~7.5", | ||
"matthiasnoback/symfony-config-test": "^4.1", | ||
"g1a/composer-test-scenarios": "^3.0" | ||
}, | ||
"autoload": { | ||
"psr-0": { | ||
"Robertfausk\\Behat\\PantherExtension": "src/" | ||
} | ||
}, | ||
"autoload-dev": { | ||
"psr-4": { | ||
"Tests\\": "../../tests/" | ||
} | ||
}, | ||
"extra": { | ||
"branch-alias": { | ||
"dev-master": "1.0.x-dev" | ||
} | ||
}, | ||
"config": { | ||
"vendor-dir": "../../vendor" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
vendor |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
{ | ||
"name": "robertfausk/behat-panther-extension", | ||
"type": "behat-extension", | ||
"description": "Symfony Panther extension for Behat", | ||
"keywords": [ | ||
"behat", | ||
"symfony", | ||
"panther", | ||
"web", | ||
"test", | ||
"browser", | ||
"gui" | ||
], | ||
"license": "MIT", | ||
"authors": [ | ||
{ | ||
"name": "Robert Freigang", | ||
"email": "[email protected]" | ||
} | ||
], | ||
"require": { | ||
"symfony/config": "^4.0", | ||
"php": ">=7.1", | ||
"behat/behat": "^3.0.5", | ||
"behat/mink-extension": "^2.0", | ||
"robertfausk/mink-panther-driver": "^1.0" | ||
}, | ||
"require-dev": { | ||
"phpunit/phpunit": "~7.5", | ||
"matthiasnoback/symfony-config-test": "^4.1", | ||
"g1a/composer-test-scenarios": "^3.0" | ||
}, | ||
"autoload": { | ||
"psr-0": { | ||
"Robertfausk\\Behat\\PantherExtension": "src/" | ||
} | ||
}, | ||
"autoload-dev": { | ||
"psr-4": { | ||
"Tests\\": "../../tests/" | ||
} | ||
}, | ||
"extra": { | ||
"branch-alias": { | ||
"dev-master": "1.0.x-dev" | ||
} | ||
}, | ||
"config": { | ||
"vendor-dir": "../../vendor" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters