It works well in simple cases. Running from Rake doesn’t work. Running rcov from rspec doesn’t work yet, either.
There are 13 unit tests that fail (12 failures and 1 error). The failures are mostly minor differences in output between MRI and JRuby. The big old up now is the one error. It appears to be a bug in the reset code. Once data collection starts, calling reset clears the callected data (desirable) and prevents new data from being collection (less desirable). I think that’s why running rcov from rspec fails.





7 responses so far ↓
Venkat // April 9, 2008 at 9:58 am
Hello:
Thanks for the update. I wish I could spend sometime to help on the pending errors or failures now.
Thanks,
Venkat.
Disaffect // June 19, 2008 at 12:08 am
Somehow i missed the point. Probably lost in translation
Anyway … nice blog to visit.
cheers, Disaffect.
Ray // July 8, 2008 at 10:18 pm
So I am trying to get this woring. Got rcov without the extension installed. Got the rcov4jr code and compiled. The problem I am getting is that the rcov4jr extension exceptions when any variables or methods are called on it. rcov tries to get the ABI, and this fails, and it is due to exception. Error “/rcov.rb:648:in `const_missing’: uninitialized constant Rcov::RCOV__ (NameError)”. I’m using jruby 1.1.2. Any help would be appreciated, as I would like to help debug the port so far…but I need the extension to work.
kofno // July 8, 2008 at 11:58 pm
Try using a trunk build of JRuby, You’re probably going to need that anyway because the tracing is borked in 1.1.2. Also, how are you running the tests?
Ray // July 9, 2008 at 2:48 pm
So I have switched to using trunk, makes no difference. I am running the tests in the rcov4jr dir using ‘jruby -S rake’. If seems if it tries to load the extension, but can’t find any of the annotations. So if I open jirb, do require ‘rcovrt’, then puts ABI, I get const missing error. I am on win XP, using jdk1.6.0_06.
Ray // July 10, 2008 at 9:41 am
So it seems that my setup may not be correct. My compiled rcovrt.jar file is bad somehow, using on compiled on a mac it loads just fine on windows. Just need to figure out why is compiles differently.
Ray // July 10, 2008 at 11:26 am
Found the problem….seems the jar creation on windows…at least my machine, doesn’t work right. I had to change the dir, vs using the jar -C option.
Leave a Comment