Weird Proc tests makes JRuby to skip the rest of the tests completely
---------------------------------------------------------------------

                 Key: JRUBY-4262
                 URL: http://jira.codehaus.org/browse/JRUBY-4262
             Project: JRuby
          Issue Type: Bug
          Components: Core Classes/Modules, RubySpec
    Affects Versions: JRuby 1.4
            Reporter: Vladimir Sizikov
            Priority: Blocker
             Fix For: JRuby 1.5


This is a blocker.

Essentially, in *both*, 1.8 and 1.9 mode, once JRuby executes
core/proc/new_spec.rb, it doesn't execute anything alse AT ALL, just
pretends :)

Take a look:

mspec -t j core/proc/new_spec.rb core

Here, I execute that evil proc/new_spec first, and then the entire
core specs, and the results are:

1427 files, 1 example, 2 expectations.

*TWO* expectations only. That explains also why you don't see the
String errors when running the whole core set, because proc/new is
before the string, and essentially the string specs are not executed
at all!!!

And the spec in  question that
breaks JRuby is:

{code}
 # This raises a ThreadError on 1.8 HEAD. Reported as bug #1707
 it "raises a LocalJumpError when context of the block no longer exists" do
   def some_method
     Proc.new { return }
   end
   res = some_method()

   # Using raise_error here causes 1.9 to hang, so we roll our own
   # begin/rescue block to verify that the exception is raised.

   exception = nil

   begin
     res.call  #### <-------------------- *** Commenting out this
line would allow to run other tests ***********
   rescue LocalJumpError => e
     exception = e
   end

   e.should be_an_instance_of(LocalJumpError)
 end
{code}

Btw, MRI works just fine here, so it does look like JRuby's issue.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to