forked from ezsystems/ezpublish-community
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add script to be able to run behat tests from other repos
- Loading branch information
Showing
2 changed files
with
28 additions
and
4 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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,28 @@ | ||
#!/bin/bash | ||
|
||
# This script is meant to be reused from other repos that needs to run behat tests. | ||
# | ||
# Example use: | ||
# | ||
# before_install: | ||
# - git fetch --unshallow && git checkout -b tmp_travis_branch | ||
# - export BRANCH_BUILD_DIR=$TRAVIS_BUILD_DIR | ||
# - export TRAVIS_BUILD_DIR="$HOME/build/ezpublish-community" | ||
# - cd "$HOME/build" | ||
# - git clone --depth 1 --single-branch --branch master https://github.com/ezsystems/ezpublish-community.git | ||
# - cd ezpublish-community | ||
# - ./bin/.travis/setup_from_external_repo.sh $BRANCH_BUILD_DIR "ezsystems/demobundle:dev-tmp_travis_branch" | ||
|
||
REPO_DIR=$1 | ||
COMPOSER_REQUIRE=$2 | ||
|
||
./bin/.travis/prepare_system.sh | ||
./bin/.travis/prepare_sahi.sh | ||
|
||
echo "> Modify composer.json to point to local checkout" | ||
sed -i '$d' composer.json | ||
echo ', "repositories": [{"type":"git","url":"'$REPO_DIR'"}]}' >> composer.json | ||
composer require --no-update "$COMPOSER_REQUIRE" | ||
cat composer.json | ||
|
||
./bin/.travis/prepare_ezpublish.sh |