Skip to content

Commit 1d178ee

Browse files
committed
Enable --error-on-warnings in test-suite
1 parent 6c6b1fd commit 1d178ee

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

test/test.sh

+7-5
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ trap 'err $LINENO' ERR
3030

3131
unset RUCKSACK_MODE
3232

33+
BUILD_FLAGS=--error-on-warnings
34+
3335
crystal run test/test.cr >$to 2>$te
3436
.
3537
RUCKSACK_MODE=0 crystal run test/test.cr >$to 2>$te
@@ -41,7 +43,7 @@ RUCKSACK_MODE=0 crystal run test/test.cr >$to 2>$te
4143

4244
### crystal build w/o rucksack attached
4345

44-
crystal build test/test.cr -o ${tb}
46+
crystal build $BUILD_FLAGS test/test.cr -o ${tb}
4547
.
4648
RUCKSACK_MODE=0 $tb >$to 2>$te
4749
.
@@ -63,7 +65,7 @@ RUCKSACK_MODE=2 $tb >$to 2>$te
6365
### crystal build with phony padding
6466

6567
#### case A: extra nulls before Knautschzone
66-
crystal build test/test.cr -o ${tb}
68+
crystal build $BUILD_FLAGS test/test.cr -o ${tb}
6769
head -c 17042 /dev/zero >>${tb}
6870
cat .rucksack >>$tb
6971
RUCKSACK_MODE=0 $tb >$to 2>$te
@@ -75,7 +77,7 @@ RUCKSACK_MODE=2 $tb >$to 2>$te
7577

7678
#### case B: duplicate padding
7779

78-
crystal build test/test.cr -o ${tb}
80+
crystal build $BUILD_FLAGS test/test.cr -o ${tb}
7981
head -c 16397 /dev/zero >>${tb}
8082
cat .rucksack >>$tb
8183
RUCKSACK_MODE=0 $tb >$to 2>$te
@@ -87,7 +89,7 @@ RUCKSACK_MODE=2 $tb >$to 2>$te
8789

8890
#### case C: extra nulls and truncated header
8991

90-
crystal build test/test.cr -o ${tb}
92+
crystal build $BUILD_FLAGS test/test.cr -o ${tb}
9193
head -c 16397 /dev/zero >>${tb}
9294
echo = >>${tb}
9395
cat .rucksack >>$tb
@@ -100,7 +102,7 @@ RUCKSACK_MODE=2 $tb >$to 2>$te
100102

101103
#### case D: extra nulls and longer truncated header
102104

103-
crystal build test/test.cr -o ${tb}
105+
crystal build $BUILD_FLAGS test/test.cr -o ${tb}
104106
head -c 16397 /dev/zero >>${tb}
105107
echo ==RUCK >>${tb}
106108
cat .rucksack >>$tb

0 commit comments

Comments
 (0)