Not all at_exit blocks are being executed.
------------------------------------------
Key: JRUBY-2809
URL: http://jira.codehaus.org/browse/JRUBY-2809
Project: JRuby
Issue Type: Bug
Components: Core Classes/Modules
Affects Versions: JRuby 1.1.2, JRuby 1.1.3
Environment: Windows XP, and Mac OSX
Reporter: Jay McGaffigan
Priority: Critical
So a coworker and I are trying to get RCov to work with JRuby and we are
almost there. However, the latest issue that's preventing it from working
centers around running rcov itself. rcov uses multiple BEGIN and END
blocks. And the problem appears to be with the END block... which I think
is an alias for at_exit.
here is an example:
If we have code like (you can replace the at_exit with end):
puts "Beginning of ruby file"
BEGIN { puts "my begin 1"}
at_exit {puts "my end 1"}
BEGIN {puts "my begin 2"}
at_exit { puts "my end 2"}
at_exit { puts "my end exit"; exit }
puts "End of ruby file"
The output in MRI is:
my begin 1
my begin 2
Beginning of ruby file
End of ruby file
my end exit
my end 2
my end 1
the output with JRuby is:
my begin 1
my begin 2
Beginning of ruby file
End of ruby file
my end exit
This is causing the latest issue with RCov in getting results to report
properly.
--
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