Skip to content

Commit c5d8c0d

Browse files
committed
Added code coverage.
1 parent caf7889 commit c5d8c0d

File tree

6 files changed

+24
-1
lines changed

6 files changed

+24
-1
lines changed

Diff for: .github/workflows/ci.yml

+15
Original file line numberDiff line numberDiff line change
@@ -37,3 +37,18 @@ jobs:
3737
run: bundle exec rspec
3838
- name: Run examples
3939
run: bundle exec ruby examples/feed.rb
40+
- name: Report Coverage
41+
uses: coverallsapp/github-action@v2
42+
with:
43+
flag-name: run-${{ join(matrix.*, '-') }}
44+
parallel: true
45+
46+
upload-coverage:
47+
needs: test
48+
if: ${{ always() }}
49+
runs-on: ubuntu-latest
50+
steps:
51+
- name: Upload Code Coverage Report
52+
uses: coverallsapp/github-action@v2
53+
with:
54+
parallel-finished: true

Diff for: .gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,4 @@
22
.bundle
33
Gemfile.lock
44
pkg/*
5+
coverage

Diff for: CHANGELOG.md

+1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
* [#44](https://github.com/mongoid/mongoid-scroll/pull/44): Drop support for Mogoid 5 and Mongo Ruby Driver - [@dblock](https://github.com/dblock).
77
* [#45](https://github.com/mongoid/mongoid-scroll/pull/45): Add support for Mogoid 9 - [@dblock](https://github.com/dblock).
88
* [#46](https://github.com/mongoid/mongoid-scroll/pull/46): Upgrade RuboCop to 1.66.1 - [@dblock](https://github.com/dblock).
9+
* [#47](https://github.com/mongoid/mongoid-scroll/pull/47): Add code coverage - [@dblock](https://github.com/dblock).
910
* Your contribution here.
1011

1112
### 1.0.1 (2023/03/15)

Diff for: Gemfile

+1
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ end
1212

1313
group :development, :test do
1414
gem 'bundler'
15+
gem 'coveralls_reborn', require: false
1516
gem 'database_cleaner', '~> 1.8.5'
1617
gem 'faker'
1718
gem 'mongoid-danger', '~> 0.2.0', require: false

Diff for: README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
[![Gem Version](https://badge.fury.io/rb/mongoid-scroll.svg)](https://badge.fury.io/rb/mongoid-scroll)
1717
[![Build Status](https://github.com/mongoid/mongoid-scroll/actions/workflows/ci.yml/badge.svg)](https://github.com/mongoid/mongoid-scroll/actions/workflows/ci.yml)
18-
[![Dependency Status](https://gemnasium.com/mongoid/mongoid-scroll.svg)](https://gemnasium.com/mongoid/mongoid-scroll)
18+
[![Coverage Status](https://coveralls.io/repos/github/mongoid/mongoid-scroll/badge.svg?branch=master)](https://coveralls.io/github/mongoid/mongoid-scroll?branch=master)
1919
[![Code Climate](https://codeclimate.com/github/mongoid/mongoid-scroll.svg)](https://codeclimate.com/github/mongoid/mongoid-scroll)
2020

2121
Mongoid extension that enables infinite scrolling for `Mongoid::Criteria` and `Mongo::Collection::View`.

Diff for: spec/spec_helper.rb

+5
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
22
$LOAD_PATH.unshift(File.dirname(__FILE__))
33

4+
require 'coveralls'
5+
Coveralls.wear! do
6+
add_filter 'spec'
7+
end
8+
49
require 'rubygems'
510
require 'rspec'
611
require 'rspec/its'

0 commit comments

Comments
 (0)