test/app_test_methods.rb in ruboto-1.0.3 vs test/app_test_methods.rb in ruboto-1.1.0

- old
+ new

@@ -14,10 +14,11 @@ # FIXME(uwe): We should try using YAML as well assert_code 'YamlLoads', "require 'yaml'" assert_code 'ReadSourceFile', 'File.read(__FILE__)' + # noinspection RubyExpressionInStringInspection assert_code 'DirListsFilesInApk', 'Dir["#{File.dirname(__FILE__)}/*"].each{|f| raise "File #{f.inspect} not found" unless File.exists?(f)}' assert_code 'RepeatRubotoImportWidget', 'ruboto_import_widget :TextView ; ruboto_import_widget :TextView' end run_activity_tests('activity') end @@ -35,12 +36,16 @@ end end def run_activity_tests(activity_dir) Dir[File.expand_path("#{activity_dir}/*", File.dirname(__FILE__))].each do |file| - # FIXME(uwe): Remove when we include jopenssl and bouncycastle - next if file =~ /ssl/ + # FIXME(uwe): Remove when we stop testing api level < 16 + # FIXME(uwe): Remove when we release RubotoCore with SSL included + next if file =~ /ssl/ && (ANDROID_OS < 16 || + RUBOTO_PLATFORM == 'CURRENT' || RUBOTO_PLATFORM == 'FROM_GEM' || + JRUBY_JARS_VERSION < Gem::Version.new('1.7.13') || + JRUBY_JARS_VERSION < Gem::Version.new('9000')) # FIXME(uwe): JRuby 9K should contain the SSLSocket fix. # EMXIF # FIXME(uwe): Remove when we stop testing JRuby < 1.7.4.dev next if file =~ /dir_and_file/ && (RUBOTO_PLATFORM == 'CURRENT' || JRUBY_JARS_VERSION < Gem::Version.new('1.7.4.dev')) # EMXIF @@ -59,10 +64,10 @@ FileUtils.cp "#{snake_name}.rb", 'src/' FileUtils.cp file, 'test/src/' end elsif !File.exists? "#{file.chomp('.rb')}'_test.rb'" Dir.chdir APP_DIR do - FileUtils.cp file, "src/" + FileUtils.cp file, 'src/' end end end run_app_tests end