Skip to content

Commit a7da0f9

Browse files
committed
make sure test_all will errexit
previously using `tee` was preventing script from exiting on test failure
1 parent 8d4ea86 commit a7da0f9

File tree

1 file changed

+25
-25
lines changed

1 file changed

+25
-25
lines changed

test_all

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -76,32 +76,32 @@ for ruby in $RUBIES ; do
7676
done
7777

7878
for ruby in $RUBIES ; do
79+
rvm_use ${ruby}
80+
echo -e "**\n** testing nokogiri on ${ruby}\n**"
81+
clean
82+
compile
83+
echo "** running tests ..."
84+
bundle exec rake test 2>&1
85+
if [[ ! $ruby =~ "jruby" ]] ; then
86+
echo "** running tests again with libxml-ruby loaded ..."
87+
if ! gem list libxml-ruby | fgrep 2.8.0 ; then
88+
gem install libxml-ruby
89+
fi
90+
bundle exec rake test:libxml-ruby 2>&1
91+
fi
92+
clean
93+
done | tee -a $TEST_LOG
94+
95+
for ruby in $RUBIES ; do
96+
if [[ ! $ruby =~ "jruby" ]] ; then
7997
rvm_use ${ruby}
80-
echo -e "**\n** testing nokogiri on ${ruby}\n**" | tee -a $TEST_LOG
98+
echo -e "**\n** nokogiri prerelease: ${ruby}\n**"
8199
clean
82100
compile
83-
echo "** running tests ..."
84-
bundle exec rake test 2>&1 | tee -a $TEST_LOG
85-
if [[ ! $ruby =~ "jruby" ]] ; then
86-
echo "** running tests again with libxml-ruby loaded ..."
87-
if ! gem list libxml-ruby | fgrep 2.8.0 ; then
88-
gem install libxml-ruby
89-
fi
90-
bundle exec rake test:libxml-ruby 2>&1 | tee -a $TEST_LOG
91-
fi
101+
echo "** running valgrind on tests ..."
102+
bundle exec rake test:valgrind 2>&1
103+
echo "** running valgrind again with libxml-ruby loaded ..."
104+
bundle exec rake test:valgrind:libxml-ruby 2>&1
92105
clean
93-
done
94-
95-
for ruby in $RUBIES ; do
96-
if [[ ! $ruby =~ "jruby" ]] ; then
97-
rvm_use ${ruby}
98-
echo -e "**\n** nokogiri prerelease: ${ruby}\n**" | tee -a $VALGRIND_LOG
99-
clean
100-
compile
101-
echo "** running valgrind on tests ..."
102-
bundle exec rake test:valgrind 2>&1 | tee -a $VALGRIND_LOG
103-
echo "** running valgrind again with libxml-ruby loaded ..."
104-
bundle exec rake test:valgrind:libxml-ruby 2>&1 | tee -a $VALGRIND_LOG
105-
clean
106-
fi
107-
done
106+
fi
107+
done | tee -a $VALGRIND_LOG

0 commit comments

Comments
 (0)