Java Exceptions doesn't follow regular exception expectations
-------------------------------------------------------------
Key: JRUBY-2242
URL: http://jira.codehaus.org/browse/JRUBY-2242
Project: JRuby
Issue Type: Bug
Components: Java Integration
Reporter: Ola Bini
Assignee: Bill Dortch
It's highly unintuitive that the following doesn't work:
{noformat}
begin
java.util.HashMap.new.entrySet.iterator.next
rescue java.util.NoSuchElementException => e
assert_equal java.util.NoSuchElementException, e.class
end
{noformat}
Instead, the class of e is NativeException. This means that no testing
frameworks can test exceptions from Java code the same way they test it from
Ruby.
--
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