[Rubygems-developers] Fwd: Bug in Rubygems: Testing of packages, missing return.

Austin Ziegler halostatue at gmail.com
Wed Jan 19 13:02:54 EST 2005


I am working with Kaspar Schiess on the release of Text::Reform (now
part of the Text Formatting project on Rubyforge) and we were doing
some checking around and found the following problem. He's also got a
resolution for you.

---------- Forwarded message ----------
From: Kaspar Schiess <eule at space.ch>
Date: Wed, 19 Jan 2005 19:01:27 +0100
Subject: Bug in Rubygems: Testing of packages, missing return.
To: Austin Ziegler <halostatue at gmail.com>

Hello Austin,

Thank you for forwarding:

Installing a package with

   gem install -t package.gem

fails with

ERROR:  While executing gem ... (NoMethodError)
     undefined method `passed?' for 0:Fixnum

because of Validator#unit_test NOT returning result. The attached patch
will fix that ('return' being optional, that's a question of style, but
it tends not to be forgotten that way.. ;) ).

--- validator.rb        Wed Jan 19 18:56:43 2005
+++ validator.rb.new    Wed Jan 19 18:55:48 2005
@@ -139,6 +139,7 @@
          #end
        end
        Dir.chdir(start_dir)
+      return result
      end

      def remove_leading_dot_dir(path)

best regards,
kaspar

hand manufactured code - www.tua.ch/ruby 




-- 
Austin Ziegler * halostatue at gmail.com
               * Alternate: austin at halostatue.ca


More information about the Rubygems-developers mailing list