Skip to content

Commit

Permalink
Use latest solcjs and replace compileStandard by compile.
Browse files Browse the repository at this point in the history
  • Loading branch information
chriseth committed Nov 6, 2018
1 parent 165d7b2 commit 52cd1b7
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
3 changes: 2 additions & 1 deletion scripts/bytecodecompare/storebytecode.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,9 @@ TMPDIR=$(mktemp -d)

if [[ "$SOLC_EMSCRIPTEN" = "On" ]]
then
# npm install solc
git clone --depth 1 https://github.com/ethereum/solc-js.git solc
cp "$REPO_ROOT/build/libsolc/soljson.js" .
npm install solc
cat > solc <<EOF
#!/usr/bin/env node
var process = require('process')
Expand Down
13 changes: 12 additions & 1 deletion test/externalTests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,16 @@ function test_truffle
cd "$DIR"
echo "Current commit hash: `git rev-parse HEAD`"
npm install
find . -name soljson.js -exec cp "$SOLJSON" {} \;
# Replace solc package by master
for d in node_modules node_modules/truffle/node_modules
do
(
cd $d
rm -rf solc
git clone --depth 1 https://github.com/ethereum/solc-js.git solc
cp "$SOLJSON" solc/
)
done
if [ "$name" == "Zeppelin" -o "$name" == "Gnosis" ]; then
echo "Replaced fixed-version pragmas..."
# Replace fixed-version pragmas in Gnosis (part of Consensys best practice)
Expand All @@ -68,6 +77,8 @@ function test_truffle
rm "$assertsol"
wget https://raw.githubusercontent.com/trufflesuite/truffle-core/ef31bcaa15dbd9bd0f6a0070a5c63f271cde2dbc/lib/testing/Assert.sol -o "$assertsol"
fi
# Change "compileStandard" to "compile"
sed -i s/solc.compileStandard/solc.compile/ "node_modules/truffle/build/cli.bundled.js"
npm run test
)
rm -rf "$DIR"
Expand Down

0 comments on commit 52cd1b7

Please sign in to comment.