Skip to content

Commit

Permalink
Switch to GH Actions for CI and add coverage reporting
Browse files Browse the repository at this point in the history
  • Loading branch information
waiting-for-dev committed Oct 26, 2023
1 parent ffecd9e commit b8dc9d8
Show file tree
Hide file tree
Showing 4 changed files with 45 additions and 11 deletions.
32 changes: 32 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: CI

on: [push, pull_request]

jobs:
build:
name: Build
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
ruby: ["3.0", "3.1", "3.2"]

steps:
- name: Checkout
uses: actions/checkout@v3

- name: Setup Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true

- name: Rake
run: bundle exec rake

- name: Archive SimpleCov Report
uses: actions/upload-artifact@v3
with:
name: coverage
path: coverage
11 changes: 0 additions & 11 deletions .travis.yml

This file was deleted.

4 changes: 4 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,7 @@ group :development do
# TODO: Move to gemspec when hanami-view 2.0 is available
gem 'hanami-view', github: 'hanami/view', tag: 'v2.1.0.beta2'
end

group :test do
gem 'simplecov', require: false
end
9 changes: 9 additions & 0 deletions spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,15 @@

require 'web_pipe'
require 'pry-byebug'
require "simplecov"

unless ENV["NO_COVERAGE"]
SimpleCov.start do
add_filter %r{^/spec/}
enable_coverage :branch
enable_coverage_for_eval
end
end

# https://github.com/dry-rb/dry-configurable/issues/70
WebPipe.load_extensions(
Expand Down

0 comments on commit b8dc9d8

Please sign in to comment.