Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Use the right js-sdk branch when testing #1869

Merged
merged 5 commits into from
May 2, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 1 addition & 8 deletions .travis-test-riot.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,9 @@ set -ev
RIOT_WEB_DIR=riot-web
REACT_SDK_DIR=`pwd`

curbranch="${TRAVIS_PULL_REQUEST_BRANCH:-$TRAVIS_BRANCH}"
echo "Determined branch to be $curbranch"

git clone https://github.com/vector-im/riot-web.git \
"$RIOT_WEB_DIR"

scripts/fetchdep.sh vector-im riot-web
cd "$RIOT_WEB_DIR"

git checkout "$curbranch" || git checkout develop

mkdir node_modules
npm install

Expand Down
1 change: 0 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,5 @@ addons:
chrome: stable
install:
- npm install
- (cd node_modules/matrix-js-sdk && npm install)
script:
./scripts/travis.sh
12 changes: 12 additions & 0 deletions scripts/fetchdep.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/bin/sh

set -e

org="$1"
repo="$2"

curbranch="${TRAVIS_PULL_REQUEST_BRANCH:-$TRAVIS_BRANCH}"
echo "Determined branch to be $curbranch"

git clone https://github.com/$org/$repo.git $repo --branch "$curbranch" || git clone https://github.com/$org/$repo.git $repo --branch develop

8 changes: 8 additions & 0 deletions scripts/travis.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@

set -ex

scripts/fetchdep.sh matrix-org matrix-js-sdk
rm -r node_modules/matrix-js-sdk || true
ln -s ../matrix-js-sdk node_modules/matrix-js-sdk

cd matrix-js-sdk
npm install
cd ..

npm run test
./.travis-test-riot.sh

Expand Down