[DRE-commits] [SCM] gem2deb.git branch, master, updated. 290116c7d752c9c48ac8852ea7cdcca5fce1a278

Antonio Terceiro terceiro at softwarelivre.org
Mon May 9 23:45:12 UTC 2011


The following commit has been merged in the master branch:
commit 290116c7d752c9c48ac8852ea7cdcca5fce1a278
Author: Antonio Terceiro <terceiro at softwarelivre.org>
Date:   Mon May 9 16:44:19 2011 -0700

    Also support debian/ruby-tests.rake
    
    This should all be documented in some point of the future. :-/

diff --git a/lib/gem2deb/dh_ruby.rb b/lib/gem2deb/dh_ruby.rb
index 9451e4a..4d6e6c7 100644
--- a/lib/gem2deb/dh_ruby.rb
+++ b/lib/gem2deb/dh_ruby.rb
@@ -247,6 +247,16 @@ module Gem2Deb
         cmd = "#{SUPPORTED_RUBY_VERSIONS[rubyver]} -Ilib debian/ruby-tests.rb"
         puts(cmd) if $VERBOSE
         system(cmd)
+      elsif File::exists?('debian/ruby-tests.rake')
+        puts "Running tests for #{rubyver} using debian/ruby-tests.rake..."
+        cmd = [
+          SUPPORTED_RUBY_VERSIONS[rubyver],
+          '-rrake',
+          '-e',
+          'ARGV.unshift("-f", "debian/ruby-tests.rake"); Rake.application.run'
+        ]
+        puts(cmd.join(' ')) if $VERBOSE
+        system(*cmd)
       else
         puts "Running tests for #{rubyver}: found no way to run a test suite!"
       end

-- 
gem2deb.git



More information about the Pkg-ruby-extras-commits mailing list