mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Handle version for solcjs tests.
This commit is contained in:
parent
981ff308ec
commit
937f16afef
@ -30,10 +30,12 @@ jobs:
|
|||||||
destination: soljson.js
|
destination: soljson.js
|
||||||
- run: mkdir -p workspace
|
- run: mkdir -p workspace
|
||||||
- run: cp build/libsolc/soljson.js workspace/soljson.js
|
- run: cp build/libsolc/soljson.js workspace/soljson.js
|
||||||
|
- run: scripts/get_version.sh > workspace/version.txt
|
||||||
- persist_to_workspace:
|
- persist_to_workspace:
|
||||||
root: workspace
|
root: workspace
|
||||||
paths:
|
paths:
|
||||||
- soljson.js
|
- soljson.js
|
||||||
|
- version.txt
|
||||||
test_emscripten_solcjs:
|
test_emscripten_solcjs:
|
||||||
docker:
|
docker:
|
||||||
- image: trzeci/emscripten:sdk-tag-1.37.21-64bit
|
- image: trzeci/emscripten:sdk-tag-1.37.21-64bit
|
||||||
@ -57,7 +59,7 @@ jobs:
|
|||||||
name: Test solcjs
|
name: Test solcjs
|
||||||
command: |
|
command: |
|
||||||
. /usr/local/nvm/nvm.sh
|
. /usr/local/nvm/nvm.sh
|
||||||
test/solcjsTests.sh /tmp/workspace/soljson.js
|
test/solcjsTests.sh /tmp/workspace/soljson.js $(cat /tmp/workspace/version.txt)
|
||||||
test_emscripten_external:
|
test_emscripten_external:
|
||||||
docker:
|
docker:
|
||||||
- image: trzeci/emscripten:sdk-tag-1.37.21-64bit
|
- image: trzeci/emscripten:sdk-tag-1.37.21-64bit
|
||||||
|
@ -30,8 +30,9 @@ set -e
|
|||||||
|
|
||||||
REPO_ROOT=$(cd $(dirname "$0")/.. && pwd)
|
REPO_ROOT=$(cd $(dirname "$0")/.. && pwd)
|
||||||
SOLJSON="$REPO_ROOT/build/libsolc/soljson.js"
|
SOLJSON="$REPO_ROOT/build/libsolc/soljson.js"
|
||||||
|
VERSION=$("$REPO_ROOT"/scripts/get_version.sh)
|
||||||
|
|
||||||
echo "Running solcjs tests...."
|
echo "Running solcjs tests...."
|
||||||
"$REPO_ROOT/test/solcjsTests.sh" "$SOLJSON"
|
"$REPO_ROOT/test/solcjsTests.sh" "$SOLJSON" "$VERSION"
|
||||||
echo "Running external tests...."
|
echo "Running external tests...."
|
||||||
"$REPO_ROOT/test/externalTests.sh" "$SOLJSON"
|
"$REPO_ROOT/test/externalTests.sh" "$SOLJSON"
|
||||||
|
@ -28,13 +28,14 @@
|
|||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
if [ ! -f "$1" ]
|
if [ ! -f "$1" -o -z "$2" ]
|
||||||
then
|
then
|
||||||
echo "Usage: $0 <path to soljson.js>"
|
echo "Usage: $0 <path to soljson.js> <version>"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
SOLJSON="$1"
|
SOLJSON="$1"
|
||||||
|
VERSION="$2"
|
||||||
|
|
||||||
DIR=$(mktemp -d)
|
DIR=$(mktemp -d)
|
||||||
(
|
(
|
||||||
@ -53,7 +54,6 @@ DIR=$(mktemp -d)
|
|||||||
cp "$SOLJSON" soljson.js
|
cp "$SOLJSON" soljson.js
|
||||||
|
|
||||||
# Update version (needed for some tests)
|
# Update version (needed for some tests)
|
||||||
VERSION=$("$REPO_ROOT/scripts/get_version.sh")
|
|
||||||
echo "Updating package.json to version $VERSION"
|
echo "Updating package.json to version $VERSION"
|
||||||
npm version --no-git-tag-version $VERSION
|
npm version --no-git-tag-version $VERSION
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user