Skip to content

Commit

Permalink
[yegor256#1207] fix codecov run
Browse files Browse the repository at this point in the history
  • Loading branch information
pnatashap committed Jan 30, 2024
1 parent 00cae0f commit af00e5c
Show file tree
Hide file tree
Showing 11 changed files with 54 additions and 6 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/codecov.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
codecov:
runs-on: ubuntu-22.04
Expand All @@ -22,5 +25,4 @@ jobs:
- uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: coverage/.resultset.json
fail_ci_if_error: true
37 changes: 37 additions & 0 deletions .simplecov
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# Copyright (c) 2016-2024 Yegor Bugayenko
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the 'Software'), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all
# copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.

SimpleCov.formatter = if Gem.win_platform?
SimpleCov::Formatter::MultiFormatter[
SimpleCov::Formatter::HTMLFormatter
]
else
SimpleCov::Formatter::MultiFormatter.new(
SimpleCov::Formatter::HTMLFormatter
)
end

SimpleCov.start do
add_filter '/test/'
add_filter '/front/'
add_filter '/liquibase/'
add_filter '/public/'
minimum_coverage 70
end
1 change: 1 addition & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ gem 'rubocop-rspec', '2.26.1', require: false
gem 'sass', '3.7.4'
gem 'sentry-raven', '3.1.2'
gem 'simplecov', '0.22.0'
gem 'simplecov-cobertura', '~> 2.1'
gem 'sinatra', '4.0.0'
gem 'sinatra-contrib', '4.0.0'
gem 'sprockets', '4.2.1'
Expand Down
4 changes: 4 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,9 @@ GEM
docile (~> 1.1)
simplecov-html (~> 0.11)
simplecov_json_formatter (~> 0.1)
simplecov-cobertura (2.1.0)
rexml
simplecov (~> 0.19)
simplecov-html (0.12.3)
simplecov_json_formatter (0.1.4)
sinatra (4.0.0)
Expand Down Expand Up @@ -289,6 +292,7 @@ DEPENDENCIES
sass (= 3.7.4)
sentry-raven (= 3.1.2)
simplecov (= 0.22.0)
simplecov-cobertura (~> 2.1)
sinatra (= 4.0.0)
sinatra-contrib (= 4.0.0)
sprockets (= 4.2.1)
Expand Down
2 changes: 1 addition & 1 deletion LICENSE.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
(The MIT License)

Copyright (c) 2019-2023 Yegor Bugayenko
Copyright (c) 2019-2024 Yegor Bugayenko

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the 'Software'), to deal
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

[![rake](https://github.com/yegor256/netbout/actions/workflows/rake.yml/badge.svg)](https://github.com/yegor256/netbout/actions/workflows/rake.yml)
[![PDD status](http://www.0pdd.com/svg?name=yegor256/netbout)](http://www.0pdd.com/p?name=yegor256/netbout)
[![Test Coverage](https://img.shields.io/codecov/c/github/yegor256/netbout.svg)](https://codecov.io/github/yegor256/netbout?branch=master)
[![Hits-of-Code](https://hitsofcode.com/github/yegor256/netbout)](https://hitsofcode.com/view/github/yegor256/netbout)
[![License](https://img.shields.io/badge/license-MIT-green.svg)](https://github.com/yegor256/netbout/blob/master/LICENSE.txt)
[![Availability at SixNines](https://www.sixnines.io/b/6fb0)](https://www.sixnines.io/h/6fb0)
Expand Down
2 changes: 1 addition & 1 deletion liquibase/2024/001-initial-schema.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<!--
(The MIT License)
Copyright (c) 2019-2023 Yegor Bugayenko
Copyright (c) 2019-2024 Yegor Bugayenko
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the 'Software'), to deal
Expand Down
2 changes: 1 addition & 1 deletion liquibase/2024/002-guests.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<!--
(The MIT License)
Copyright (c) 2019-2023 Yegor Bugayenko
Copyright (c) 2019-2024 Yegor Bugayenko
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the 'Software'), to deal
Expand Down
2 changes: 1 addition & 1 deletion liquibase/2024/003-token.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<!--
(The MIT License)
Copyright (c) 2019-2023 Yegor Bugayenko
Copyright (c) 2019-2024 Yegor Bugayenko
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the 'Software'), to deal
Expand Down
2 changes: 1 addition & 1 deletion liquibase/master.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<!--
(The MIT License)
Copyright (c) 2019-2023 Yegor Bugayenko
Copyright (c) 2019-2024 Yegor Bugayenko
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the 'Software'), to deal
Expand Down
3 changes: 3 additions & 0 deletions test/test__helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@
require 'simplecov'
SimpleCov.start

require 'simplecov-cobertura'
SimpleCov.formatter = SimpleCov::Formatter::CoberturaFormatter

require 'yaml'
require 'minitest/autorun'
require 'pgtk/pool'
Expand Down

0 comments on commit af00e5c

Please sign in to comment.