simplecov-cobertura
simplecov-cobertura copied to clipboard
undefined method 'formatter=' for module SimpleCov on `3.1.0`
In the description under "Usage" the following instruction can be read:
require 'simplecov-cobertura'
SimpleCov.formatter = SimpleCov::Formatter::CoberturaFormatter
But if you do it after with 3.1.0 the following error message can be read:
Failure/Error: SimpleCov.formatter = SimpleCov::Formatter::CoberturaFormatter
NoMethodError:
undefined method 'formatter=' for module SimpleCov
But if you do it in 2.1.0, this error is not present.
I'm having this same issue. @jessebs is there a workaround for this? I'm trying to upgrade from 2.1.0. Relevant merge request on GitLab.
Thanks!
require 'simplecov'
require 'simplecov-cobertura'
SimpleCov.formatter = SimpleCov::Formatter::CoberturaFormatter
Adding explicit require for 'simplecov' worked for me