environment:
  matrix:
  - TARGET: x86_64-pc-windows-msvc
  - TARGET: x86_64-pc-windows-gnu
  - TARGET: i686-pc-windows-msvc
  - TARGET: i686-pc-windows-gnu
install:
  - ps: >-
        If ($Env:TARGET -eq 'x86_64-pc-windows-gnu') {
          $Env:PATH += ';C:\msys64\mingw64\bin'
        } ElseIf ($Env:TARGET -eq 'i686-pc-windows-gnu') {
          $Env:PATH += ';C:\MinGW\bin'
        }
  - ps: Start-FileDownload "https://static.rust-lang.org/dist/rust-nightly-${env:TARGET}.exe"
  - rust-nightly-%TARGET%.exe /VERYSILENT /NORESTART /DIR="C:\Program Files (x86)\Rust"
  - SET PATH=%PATH%;C:\Program Files (x86)\Rust\bin
  - rustc -V
  - cargo -V

build: false

test_script:
  - cargo test --verbose --target %TARGET%
  - cargo test --verbose --target %TARGET% --features tokio
