name: Windows

on:
  pull_request:
    paths-ignore:
      - "*.md"
      - "./site/**/*"
  push:
    paths-ignore:
      - "*.md"
      - "./site/**/*"

env:
  CARGO_TERM_COLOR: always

jobs:
  build:
    runs-on: windows-2019

    steps:
      - uses: actions/checkout@v2
      - uses: dtolnay/rust-toolchain@stable
        with:
          toolchain: stable
          components: rustfmt, clippy
      - name: Build
        run: cargo build
      - name: Run tests
        run: cargo test --verbose --features github-actions
      - name: Clippy
        run: cargo clippy -- -Dwarnings
