Skip to content

Commit

Permalink
build: drop Travis in favor of Actions
Browse files Browse the repository at this point in the history
GitHub Actions is running all tests already present on Travis, as well
as building on more platforms (OS X and Windows). With Travis we're also
getting timeouts more frequently than with Actions, which gives the
false impression tests are failing (making it harder to triage PRs ready
to merge).

To make our config simpler, CI.yml and pythonpackage.yml got merged. The
coverage is also increased by running tests on OS X.

Signed-off-by: Matheus Marchini <mmarchini@netflix.com>

PR-URL: nodejs#32450
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Christian Clauss <cclauss@me.com>
Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Ben Coe <bencoe@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
  • Loading branch information
cclauss authored and MylesBorins committed Apr 2, 2020
1 parent c2e00ed commit 9d80c47
Show file tree
Hide file tree
Showing 10 changed files with 167 additions and 212 deletions.
79 changes: 0 additions & 79 deletions .github/workflows/CI.yml

This file was deleted.

23 changes: 23 additions & 0 deletions .github/workflows/build-windows.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: build-windows

on: [push, pull_request]

env:
PYTHON_VERSION: 3.8
FLAKY_TESTS: dontcare

jobs:
build-windows:
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@v1
with:
PYTHON_VERSION: ${{ env.PYTHON_VERSION }}
- name: Install deps
run: choco install nasm
- name: Environment Information
run: npx envinfo
- name: Build
run: ./vcbuild.bat
73 changes: 73 additions & 0 deletions .github/workflows/linters.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
name: linters

on: [push, pull_request]

env:
PYTHON_VERSION: 3.8
NODE_VERSION: 10.x

jobs:
lint-addon-docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ env.NODE_VERSION }}
uses: actions/setup-node@v1
with:
node-version: ${{ env.NODE_VERSION }}
- name: Environment Information
run: npx envinfo
- name: Lint addon docs
run: NODE=$(which node) make lint-addon-docs
lint-cpp:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@v1
with:
PYTHON_VERSION: ${{ env.PYTHON_VERSION }}
- name: Environment Information
run: npx envinfo
- name: Lint C/C++ files
run: make lint-cpp
lint-md:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ env.NODE_VERSION }}
uses: actions/setup-node@v1
with:
node-version: ${{ env.NODE_VERSION }}
- name: Environment Information
run: npx envinfo
- name: Lint docs
run: |
echo "::add-matcher::.github/workflows/remark-lint-problem-matcher.json"
NODE=$(which node) make lint-md
lint-js:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ env.NODE_VERSION }}
uses: actions/setup-node@v1
with:
node-version: ${{ env.NODE_VERSION }}
- name: Environment Information
run: npx envinfo
- name: Lint JavaScript files
run: NODE=$(which node) make lint-js
lint-py:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@v1
with:
PYTHON_VERSION: ${{ env.PYTHON_VERSION }}
- name: Environment Information
run: npx envinfo
- name: Lint Python
run: |
make lint-py-build || true
NODE=$(which node) make lint lint-py
24 changes: 24 additions & 0 deletions .github/workflows/misc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: misc

on: [push, pull_request]

env:
NODE_VERSION: 12.x

jobs:
build-docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ env.NODE_VERSION }}
uses: actions/setup-node@v1
with:
node-version: ${{ env.NODE_VERSION }}
- name: Environment Information
run: npx envinfo
- name: Build
run: NODE=$(which node) make doc-only
- uses: actions/upload-artifact@v1
with:
name: docs
path: out/doc
33 changes: 0 additions & 33 deletions .github/workflows/pythonpackage.yml

This file was deleted.

23 changes: 23 additions & 0 deletions .github/workflows/test-linux.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: test-linux

on: [push, pull_request]

env:
PYTHON_VERSION: 3.8
FLAKY_TESTS: dontcare

jobs:
test-linux:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@v1
with:
PYTHON_VERSION: ${{ env.PYTHON_VERSION }}
- name: Environment Information
run: npx envinfo
- name: Build
run: make build-ci -j2 V=1
- name: Test
run: make run-ci -j2 V=1
23 changes: 23 additions & 0 deletions .github/workflows/test-macos.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: test-macOS

on: [push, pull_request]

env:
PYTHON_VERSION: 3.8
FLAKY_TESTS: dontcare

jobs:
test-macOS:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@v1
with:
PYTHON_VERSION: ${{ env.PYTHON_VERSION }}
- name: Environment Information
run: npx envinfo
- name: Build
run: make build-ci -j8 V=1
- name: Test
run: make run-ci -j8 V=1
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
!.gitkeep
!.mailmap
!.nycrc
!.travis.yml
!.eslintrc.yaml
!.cpplint

Expand Down
91 changes: 0 additions & 91 deletions .travis.yml

This file was deleted.

Loading

0 comments on commit 9d80c47

Please sign in to comment.