Skip to content

Commit

Permalink
Merge pull request #10 from mmainz/add-coveralls
Browse files Browse the repository at this point in the history
Add coveralls.io
  • Loading branch information
Mario Mainz authored Aug 24, 2023
2 parents 807a33a + ef27a7f commit ac474fa
Show file tree
Hide file tree
Showing 6 changed files with 30 additions and 6 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,6 @@ jobs:

- name: Run tests ⚙️
run: bundle exec rake

- name: Coverage 📊
uses: coverallsapp/github-action@v2
10 changes: 10 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ GEM
specs:
ast (2.4.0)
diff-lcs (1.3)
docile (1.4.0)
jaro_winkler (1.5.4)
parallel (1.19.1)
parser (2.7.0.4)
Expand Down Expand Up @@ -39,6 +40,13 @@ GEM
rubocop-rspec (1.38.1)
rubocop (>= 0.68.1)
ruby-progressbar (1.10.1)
simplecov (0.22.0)
docile (~> 1.1)
simplecov-html (~> 0.11)
simplecov_json_formatter (~> 0.1)
simplecov-html (0.12.3)
simplecov-lcov (0.8.0)
simplecov_json_formatter (0.1.4)
unicode-display_width (1.6.1)

PLATFORMS
Expand All @@ -50,6 +58,8 @@ DEPENDENCIES
rspec (~> 3.0)
rubocop (~> 0.80)
rubocop-rspec (~> 1.38)
simplecov (~> 0.22)
simplecov-lcov (~> 0.8)
valued!

BUNDLED WITH
Expand Down
8 changes: 5 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[![Build Status](https://travis-ci.org/mmainz/valued.svg?branch=master)](https://travis-ci.org/mmainz/valued)
[![Coverage Status](https://coveralls.io/repos/github/mmainz/valued/badge.svg?branch=master)](https://coveralls.io/github/mmainz/valued?branch=master)

# Valued

Expand Down Expand Up @@ -82,7 +82,8 @@ p quantity
=> #<Quantity amount=2 unit="m">
```

You can create a duplicate of your object with updated attributes by using `update`.
You can create a duplicate of your object with updated attributes by using
`update`.

```ruby
quantity = Quantity.new(unit: 'm', amount: 2)
Expand All @@ -93,7 +94,8 @@ p updated_quantity
=> #<Quantity amount=2 unit="yard">
```

If you really need a mutable object, just use `Valued::Mutable` instead of `Valued`.
If you really need a mutable object, just use `Valued::Mutable` instead of
`Valued`.

```ruby
require 'valued'
Expand Down
1 change: 1 addition & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions spec/spec_helper.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
require 'simplecov'
require 'simplecov-lcov'
SimpleCov::Formatter::LcovFormatter.config.report_with_single_file = true
SimpleCov.formatter = SimpleCov::Formatter::LcovFormatter
SimpleCov.start { add_filter '/spec/' }

require 'bundler/setup'
require 'valued'
require 'valued/shared_examples/valued_shared_examples'
Expand Down
8 changes: 5 additions & 3 deletions valued.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ Gem::Specification.new do |spec|

spec.files =
Dir.chdir(File.expand_path('..', __FILE__)) do
`git ls-files -z`.split("\x0").reject do |f|
f.match(%r{^(test|spec|features)/})
`git ls-files -z`.split("\x0").reject do |f|
f.match(%r{^(test|spec|features)/})
end
end
end

spec.bindir = 'exe'
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
Expand All @@ -31,4 +31,6 @@ Gem::Specification.new do |spec|
spec.add_development_dependency 'rspec', '~> 3.0'
spec.add_development_dependency 'rubocop', '~> 0.80'
spec.add_development_dependency 'rubocop-rspec', '~> 1.38'
spec.add_development_dependency 'simplecov', '~> 0.22'
spec.add_development_dependency 'simplecov-lcov', '~> 0.8'
end

0 comments on commit ac474fa

Please sign in to comment.