Remove pre-release warning from standard json cmdline tests.

This commit is contained in:
Daniel Kirchner 2018-12-13 13:31:12 +01:00
parent 6e205cc4e3
commit d5a50d8aee
2 changed files with 8 additions and 3 deletions

View File

@ -130,8 +130,13 @@ test_solc_behaviour() {
exitCode=$? exitCode=$?
set -e set -e
sed -i -e '/^Warning: This is a pre-release compiler version, please do not use it in production./d' "$stderr_path" if [[ "$solc_args" == *"--standard-json"* ]]; then
sed -i -e 's/ Consider adding "pragma .*$//' "$stderr_path" sed -i -e 's/{[^{]*Warning: This is a pre-release compiler version[^}]*},\{0,1\}//' "$stdout_path"
sed -i -e 's/,"errors":\[\]//' "$stdout_path"
else
sed -i -e '/^Warning: This is a pre-release compiler version, please do not use it in production./d' "$stderr_path"
sed -i -e 's/ Consider adding "pragma .*$//' "$stderr_path"
fi
if [[ $exitCode -ne "$exit_code_expected" ]]; then if [[ $exitCode -ne "$exit_code_expected" ]]; then
printError "Incorrect exit code. Expected $exit_code_expected but got $exitCode." printError "Incorrect exit code. Expected $exit_code_expected but got $exitCode."

View File

@ -1 +1 @@
{"contracts":{"A":{"C":{"evm":{}}}},"errors":[{"component":"general","formattedMessage":"Warning: This is a pre-release compiler version, please do not use it in production.\n","message":"This is a pre-release compiler version, please do not use it in production.","severity":"warning","type":"Warning"}],"sources":{"A":{"id":0}}} {"contracts":{"A":{"C":{"evm":{}}}},"sources":{"A":{"id":0}}}