Skip to content

Commit

Permalink
Test: Introduce github action, and stop tests with travis-ci and appv…
Browse files Browse the repository at this point in the history
…eyor.
  • Loading branch information
sttk committed Apr 4, 2021
1 parent 0af4337 commit 503b82d
Show file tree
Hide file tree
Showing 4 changed files with 81 additions and 42 deletions.
78 changes: 78 additions & 0 deletions .github/workflows/dev.yml
@@ -0,0 +1,78 @@
name: dev
on:
pull_request:
push:
branches:

env:
CI: true

jobs:
prettier:
name: Format code
runs-on: ubuntu-latest
if: |
github.event_name == 'push' &&
github.ref == 'refs/heads/master' &&
github.repository_owner == 'gulpjs'
steps:
- name: Checkout
uses: actions/checkout@v2

- name: Prettier
uses: gulpjs/prettier_action@v3.0
with:
commit_message: 'Build: Run prettier'
prettier_options: '--write .'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

test:
name: Tests for Node ${{ matrix.node }} on ${{ matrix.os }}
runs-on: ${{ matrix.os }}

steps:
- name: Clone repository
uses: actions/checkout@v2

- name: Set Node.js version
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node }}

- run: node --version
- run: npm --version

- name: Install npm dependencies
run: npm install

- name: Run lint and test
run: npm test

- name: Coveralls Parallel
uses: coverallsapp/github-action@v1.1.0
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
parallel: true
env:
COVERALLS_FLAG_NAME: ${{matrix.os}}-node-${{ matrix.node }}

strategy:
fail-fast: false
matrix:
node: [10, 12, 14]
os: [ubuntu-latest, windows-latest, macos-latest]

coveralls:
name: Finish up
runs-on: ubuntu-latest
needs: test

steps:
- name: Coveralls Finished
uses: coverallsapp/github-action@v1.1.0
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
parallel-finished: true

11 changes: 0 additions & 11 deletions .travis.yml

This file was deleted.

8 changes: 3 additions & 5 deletions README.md
Expand Up @@ -6,7 +6,7 @@

# rechoir

[![NPM version][npm-image]][npm-url] [![Downloads][downloads-image]][npm-url] [![Travis Build Status][travis-image]][travis-url] [![AppVeyor Build Status][appveyor-image]][appveyor-url] [![Coveralls Status][coveralls-image]][coveralls-url]
[![NPM version][npm-image]][npm-url] [![Downloads][downloads-image]][npm-url] [![Build Status][ci-image]][ci-url] [![Coveralls Status][coveralls-image]][coveralls-url]

Prepare a node environment to require files with different extensions.

Expand Down Expand Up @@ -67,10 +67,8 @@ MIT
[downloads-image]: https://img.shields.io/npm/dm/rechoir.svg?style=flat-square
[npm-url]: https://www.npmjs.com/package/rechoir
[npm-image]: https://img.shields.io/npm/v/rechoir.svg?style=flat-square
[travis-url]: https://travis-ci.org/gulpjs/rechoir
[travis-image]: https://img.shields.io/travis/gulpjs/rechoir.svg?label=travis-ci
[appveyor-url]: https://ci.appveyor.com/project/gulpjs/rechoir
[appveyor-image]: https://img.shields.io/appveyor/ci/gulpjs/rechoir.svg?label=appveyor
[ci-url]: https://github.com/gulpjs/rechoir/actions?query=workflow:dev
[ci-image]: https://img.shields.io/github/workflow/status/gulpjs/rechoir/dev?style=flat-square
[coveralls-url]: https://coveralls.io/r/gulpjs/rechoir
[coveralls-image]: https://img.shields.io/coveralls/gulpjs/rechoir/master.svg
[tidelift-url]: https://tidelift.com/subscription/pkg/npm-rechoir?utm_source=npm-rechoir&utm_medium=referral&utm_campaign=enterprise&utm_term=repo
Expand Down
26 changes: 0 additions & 26 deletions appveyor.yml

This file was deleted.

0 comments on commit 503b82d

Please sign in to comment.