mirror of
https://github.com/puppetlabs/vmfloaty.git
synced 2026-01-26 05:28:40 -05:00
This adds Dependabot to keep things updated and Coveralls so we can see how code coverage changes over time. Coveralls / SimpleCov are configured so that both the SimpleCov html report and the Coveralls report are generated. This facilitates easily seeing coverage locally in addtion to via CI.
28 lines
593 B
Ruby
28 lines
593 B
Ruby
# frozen_string_literal: true
|
|
|
|
require 'simplecov'
|
|
require 'coveralls'
|
|
|
|
SimpleCov.formatter = SimpleCov::Formatter::MultiFormatter.new([
|
|
SimpleCov::Formatter::HTMLFormatter,
|
|
Coveralls::SimpleCov::Formatter
|
|
])
|
|
SimpleCov.start do
|
|
add_filter %r{^/spec/}
|
|
end
|
|
|
|
require 'vmfloaty'
|
|
require 'webmock/rspec'
|
|
|
|
# Mock Commander Options object to allow pre-population with values
|
|
class MockOptions < Commander::Command::Options
|
|
def initialize(values = {})
|
|
@table = values
|
|
end
|
|
end
|
|
|
|
RSpec.configure do |config|
|
|
config.color = true
|
|
config.tty = true
|
|
config.formatter = :documentation
|
|
end
|