add specs for different underlying behavior in JRuby