name: Standard checks

on:
  push:
    branches: [ master ]
  pull_request:
    branches: [ master ]

jobs:
  ci:
    runs-on: ubuntu-latest
    strategy:
      matrix:
        rust:
#          - stable
#          - beta
          - nightly
#          - 1.31.0  # MSRV

    steps:
      - uses: actions/checkout@v2

      - uses: actions-rs/toolchain@v1
        with:
          profile: minimal
          toolchain: ${{ matrix.rust }}
          override: true
          components: rustfmt

      - uses: actions-rs/cargo@v1
        with:
          command: build

      - uses: actions-rs/cargo@v1
        with:
          command: build
          args: --all-features

      - uses: actions-rs/cargo@v1
        with:
          command: test

      - uses: actions-rs/cargo@v1
        with:
          command: test
          args: --features performance-counter #--all-features  will currently fail

      - uses: actions-rs/cargo@v1
        with:
          command: fmt
          args: --all -- --check

Use GitHub Actions to build and test
Use GitHub Actions to build and test

This commit enables GitHub Actions to build both the standard
feature set and all features. The tests are only run for the standard
feature set and the performance-counter feature, as all features
currently fail with an error message.
