Skip to content

Commit

Permalink
* Fixed bug in test: platform was not uninstalled properly.
Browse files Browse the repository at this point in the history
  • Loading branch information
donv committed Sep 23, 2012
1 parent aa19afa commit ee419ce
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
1 change: 1 addition & 0 deletions .gitignore
Expand Up @@ -6,4 +6,5 @@ tmp
.idea .idea
*~ *~
/.rbx /.rbx
/adb_logcat.log
/exportToHTML /exportToHTML
7 changes: 5 additions & 2 deletions matrix_tests.sh
Expand Up @@ -3,11 +3,14 @@
MASTER=1.7.0.preview2 MASTER=1.7.0.preview2


export ANDROID_TARGET RUBOTO_PLATFORM JRUBY_JARS_VERSION export ANDROID_TARGET RUBOTO_PLATFORM JRUBY_JARS_VERSION
export SKIP_RUBOTO_UPDATE_TEST=1


for ANDROID_TARGET in 10 15 ; do for ANDROID_TARGET in 10 15 ; do
set +e set +e
killall emulator-arm killall emulator-arm
sleep 5 sleep 5
killall -9 emulator-arm
sleep 1
set -e set -e
if [ "$ANDROID_TARGET" == "15" ] ; then if [ "$ANDROID_TARGET" == "15" ] ; then
avd="Android_4.0.3" avd="Android_4.0.3"
Expand All @@ -17,7 +20,7 @@ for ANDROID_TARGET in 10 15 ; do


emulator -avd $avd -no-snapshot-load -no-snapshot-save & emulator -avd $avd -no-snapshot-load -no-snapshot-save &
adb wait-for-device adb wait-for-device
adb logcat > tmp/adb_logcat.txt & adb logcat > adb_logcat.log &


( (
set +e set +e
Expand All @@ -35,7 +38,7 @@ for ANDROID_TARGET in 10 15 ; do
exit 1 exit 1
) & ) &


for RUBOTO_PLATFORM in FROM_GEM STANDALONE CURRENT ; do # CURRENT FROM_GEM STANDALONE for RUBOTO_PLATFORM in CURRENT FROM_GEM STANDALONE ; do
if [ "$RUBOTO_PLATFORM" == "STANDALONE" ] ; then if [ "$RUBOTO_PLATFORM" == "STANDALONE" ] ; then
jruby_versions="$MASTER 1.6.8 1.6.7.2" jruby_versions="$MASTER 1.6.8 1.6.7.2"
elif [ "$RUBOTO_PLATFORM" == "FROM_GEM" ] ; then elif [ "$RUBOTO_PLATFORM" == "FROM_GEM" ] ; then
Expand Down
6 changes: 3 additions & 3 deletions test/test_helper.rb
Expand Up @@ -250,7 +250,7 @@ def run_app_tests
puts "Skipping instrumentation tests on #{ANDROID_OS} since they don't work." puts "Skipping instrumentation tests on #{ANDROID_OS} since they don't work."
return return
end end
check_platform_installation(Dir['libs/jruby-core-*.jar'].any?) check_platform_installation
Dir.chdir APP_DIR do Dir.chdir APP_DIR do
# FIXME(uwe): Simplify when we stop supporting JRuby < 1.7.0 which causes the ArrayIndexOutOfBoundsException # FIXME(uwe): Simplify when we stop supporting JRuby < 1.7.0 which causes the ArrayIndexOutOfBoundsException
# FIXME(uwe): Simplify if we find a cause for the system crashes. # FIXME(uwe): Simplify if we find a cause for the system crashes.
Expand Down Expand Up @@ -280,8 +280,8 @@ def run_app_tests
end end
end end


def check_platform_installation(standalone) def check_platform_installation
if standalone if RUBOTO_PLATFORM == 'STANDALONE'
system 'rake platform:uninstall' system 'rake platform:uninstall'
elsif RUBOTO_PLATFORM == 'CURRENT' elsif RUBOTO_PLATFORM == 'CURRENT'
system "rake platform:current platform:install" system "rake platform:current platform:install"
Expand Down

0 comments on commit ee419ce

Please sign in to comment.