Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch to GitHub Actions for CI #57

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
72 changes: 72 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
on: [push, pull_request]

name: CI
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
with:
submodules: true
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true

# make sure all code has been formatted with rustfmt
- run: rustup component add rustfmt
- name: check rustfmt
uses: actions-rs/cargo@v1
with:
command: fmt
args: -- --check --color always

# run clippy to verify we have no warnings
- run: rustup component add clippy
- name: cargo clippy
uses: actions-rs/cargo@v1
with:
command: clippy
args: --all --tests -- -D warnings
- name: cargo clippy (all features)
uses: actions-rs/cargo@v1
with:
command: clippy
args: --all --tests --all-features -- -D warnings

test:
name: Test
strategy:
matrix:
os: [ubuntu-latest, macOS-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v1
with:
submodules: true
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true

# test default features
- name: test
uses: actions-rs/cargo@v1
with:
command: test
args: --all

# test all features
- name: test (all features)
uses: actions-rs/cargo@v1
with:
command: test
args: --all-features

# run a query
- name: run
uses: actions-rs/cargo@v1
with:
command: run
args: -- --search car --headless --verbose
12 changes: 0 additions & 12 deletions .travis.yml

This file was deleted.

Loading