rcov v9.9 running under jruby 1.5
The following snippet results in the elsif not having been covered (hightlighted red) even though a specific rspec test
triggers the action.
# set the attribute values if all have been specified
if !pos.nil? && !lg.nil? && !fmt.nil?
# assign attribute values
self.pos = pos
self.lg = lg
self.fmt = fmt
# allow an empty instance if all the attributes are nil. This occurs when
# a def_entry is created.
elsif pos.nil? && lg.nil? && fmt.nil?
else
raise ArgumentError, 'All or none when specifying Fmt_Entry attributes.'
end
Good luck and have a good one!
|