Skip to content

Commit 4ad408f

Browse files
committed
Merge #782: Check if variable=yes instead of if var is set in travis.sh
34debf7 Modify .travis.yml to explictly pass no in env vars instead of setting to nothing (Elichai Turkel) ef37761 Change travis.sh to check if variables are equal to yes instead of not-empty. Before this, setting `VALGRIND=wat` was considered as true, and to make it evaluate as false you had to unset the variable `VALGRIND=` but not it checks if `VALGRIND=yes` and if it's not `yes` then it's evaluated to false (Elichai Turkel) Pull request description: ACKs for top commit: real-or-random: ACK 34debf7 jonasnick: ACK 34debf7 Tree-SHA512: 91becfbc9cb7587ee55b2bceb604ea0aed8860990d63a5f414b11db92180c090ea8bcc048c2fb67a094e892138e3be46f00562bf78b7c3369232457289cde447
2 parents a0e99fc + 34debf7 commit 4ad408f

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

.travis.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,9 @@ env:
3131
- BIGNUM=no
3232
- BIGNUM=no ENDOMORPHISM=yes RECOVERY=yes EXPERIMENTAL=yes SCHNORRSIG=yes
3333
- BIGNUM=no STATICPRECOMPUTATION=no
34-
- BUILD=distcheck CTIMETEST= BENCH=
34+
- BUILD=distcheck CTIMETEST=no BENCH=no
3535
- CPPFLAGS=-DDETERMINISTIC
36-
- CFLAGS=-O0 CTIMETEST=
36+
- CFLAGS=-O0 CTIMETEST=no
3737
- ECMULTGENPRECISION=2
3838
- ECMULTGENPRECISION=8
3939
- VALGRIND=yes ENDOMORPHISM=yes BIGNUM=no ASM=x86_64 EXPERIMENTAL=yes ECDH=yes RECOVERY=yes EXTRAFLAGS="--disable-openssl-tests" CPPFLAGS=-DVALGRIND BUILD=

contrib/travis.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,16 +24,16 @@ if [ -n "$BUILD" ]
2424
then
2525
make -j2 "$BUILD"
2626
fi
27-
if [ -n "$VALGRIND" ]
27+
if [ "$VALGRIND" = "yes" ]
2828
then
2929
make -j2
3030
# the `--error-exitcode` is required to make the test fail if valgrind found errors, otherwise it'll return 0 (http://valgrind.org/docs/manual/manual-core.html)
3131
valgrind --error-exitcode=42 ./tests 16
3232
valgrind --error-exitcode=42 ./exhaustive_tests
3333
fi
34-
if [ -n "$BENCH" ]
34+
if [ "$BENCH" = "yes" ]
3535
then
36-
if [ -n "$VALGRIND" ]
36+
if [ "$VALGRIND" = "yes" ]
3737
then
3838
# Using the local `libtool` because on macOS the system's libtool has nothing to do with GNU libtool
3939
EXEC='./libtool --mode=execute valgrind --error-exitcode=42'
@@ -61,7 +61,7 @@ then
6161
$EXEC ./bench_schnorrsig >> bench.log 2>&1
6262
fi
6363
fi
64-
if [ -n "$CTIMETEST" ]
64+
if [ "$CTIMETEST" = "yes" ]
6565
then
6666
./libtool --mode=execute valgrind --error-exitcode=42 ./valgrind_ctime_test > valgrind_ctime_test.log 2>&1
6767
fi

0 commit comments

Comments
 (0)