Skip to content

Commit

Permalink
Replace AppVeyor with GitHub Actions (#7893)
Browse files Browse the repository at this point in the history
  • Loading branch information
MSP-Greg authored Apr 20, 2020
1 parent 079fa63 commit 6940bb5
Show file tree
Hide file tree
Showing 5 changed files with 49 additions and 27 deletions.
45 changes: 45 additions & 0 deletions .github/workflows/rubocop.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: CI

on: [push, pull_request]

jobs:
main:
name: >-
${{ matrix.os }} ${{ matrix.ruby }}
runs-on: ${{ matrix.os }}-latest
env:
# See https://github.com/tmm1/test-queue#environment-variables
TEST_QUEUE_WORKERS: 2
strategy:
fail-fast: false
matrix:
# [ ubuntu, macos, windows ]
os: [ windows ]
ruby: [ 2.4, 2.5, 2.6, 2.7, head ]
include:
- { os: windows, ruby: mingw }
exclude:
- { os: windows, ruby: head }

steps:
- name: windows misc
if: matrix.os == 'windows'
run: |
# set TMPDIR, git core.autocrlf
echo "::set-env name=TMPDIR::$env:RUNNER_TEMP"
git config --system core.autocrlf false
- name: checkout
uses: actions/checkout@v2
- name: set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}

- name: install dependencies
run: bundle install --jobs 3 --retry 3
- name: spec
run: bundle exec rake spec
- name: ascii_spec
run: bundle exec rake ascii_spec
- name: internal_investigation
run: bundle exec rake internal_investigation
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[![Gem Version](https://badge.fury.io/rb/rubocop.svg)](https://badge.fury.io/rb/rubocop)
[![CircleCI Status](https://circleci.com/gh/rubocop-hq/rubocop/tree/master.svg?style=svg)](https://circleci.com/gh/rubocop-hq/rubocop/tree/master)
[![AppVeyor Status](https://ci.appveyor.com/api/projects/status/sj3ye7n5690d0nvg?svg=true)](https://ci.appveyor.com/project/bbatsov/rubocop)
[![Actions Status](https://github.com/rubocop-hq/rubocop/workflows/CI/badge.svg?branch=master)](https://github.com/rubocop-hq/rubocop/actions?query=workflow%3ACI)
[![Coverage Status](https://api.codeclimate.com/v1/badges/ad6e76460499c8c99697/test_coverage)](https://codeclimate.com/github/bbatsov/rubocop)
[![Code Climate](https://codeclimate.com/github/bbatsov/rubocop/badges/gpa.svg)](https://codeclimate.com/github/bbatsov/rubocop)
[![Inline docs](https://inch-ci.org/github/bbatsov/rubocop.svg)](https://inch-ci.org/github/bbatsov/rubocop)
Expand Down
23 changes: 0 additions & 23 deletions appveyor.yml

This file was deleted.

4 changes: 2 additions & 2 deletions spec/rubocop/config_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -448,7 +448,7 @@

it 'generates valid absolute directory' do
excludes = configuration['AllCops']['Exclude']
.map { |e| e.sub(/^[A-Z]:/, '') }
.map { |e| e.sub(/^[A-Z]:/i, '') }
expect(excludes)
.to eq [
'/home/foo/project/config/environment',
Expand Down Expand Up @@ -478,7 +478,7 @@

it 'generates valid absolute directory' do
excludes = configuration['AllCops']['Exclude']
.map { |e| e.sub(/^[A-Z]:/, '') }
.map { |e| e.sub(/^[A-Z]:/i, '') }
expect(excludes)
.to eq [
'/home/foo/project/config/environment',
Expand Down
2 changes: 1 addition & 1 deletion spec/rubocop/target_finder_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@
it 'returns absolute paths' do
expect(found_files.empty?).to be(false)
found_files.each do |file|
expect(file.sub(/^[A-Z]:/, '')).to start_with('/')
expect(file.sub(/^[A-Z]:/i, '')).to start_with('/')
end
end

Expand Down

0 comments on commit 6940bb5

Please sign in to comment.