Skip to content

Commit

Permalink
Migrate off appveyor to github actions (#94)
Browse files Browse the repository at this point in the history
Based and thanks to previous attempts of
@Jake-Shadle
  • Loading branch information
steffengy authored Jul 3, 2023
1 parent ea4ffcf commit 703b8bb
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 29 deletions.
42 changes: 42 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
on:
push:
pull_request:

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

env:
CARGO_INCREMENTAL: 0
RUST_TEST_THREADS: 1

jobs:

test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [windows-2022, windows-2019]
target:
[x86_64-pc-windows-msvc, i686-pc-windows-msvc, x86_64-pc-windows-gnu]
channel: [nightly]
include:
- target: i686-pc-windows-gnu
channel: 1.46.0
os: windows-2022
steps:
- uses: actions/checkout@v3
- uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ matrix.channel }}
target: ${{ matrix.target }}
- if: matrix.target == 'i686-pc-windows-gnu'
uses: MinoruSekine/setup-scoop@main
- if: matrix.target == 'i686-pc-windows-gnu'
run: |
scoop install -a 32bit mingw
Join-Path (Resolve-Path ~).Path "scoop\apps\mingw\current\bin" >> $env:GITHUB_PATH
- shell: cmd
run: ./update_test_cert.bat
- run: cargo +${{ matrix.channel }} build --tests --target ${{ matrix.target }}
- run: cargo +${{ matrix.channel }} test --target ${{ matrix.target }}
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
schannel-rs [![Build status](https://ci.appveyor.com/api/projects/status/vefyauaf0oj10swu/branch/master?svg=true)](https://ci.appveyor.com/project/steffengy/schannel-rs/branch/master)
schannel-rs [![.github/workflows/ci.yaml](https://github.com/steffengy/schannel-rs/actions/workflows/ci.yaml/badge.svg)](https://github.com/steffengy/schannel-rs/actions/workflows/ci.yaml)
=====

[Documentation](https://docs.rs/schannel/0/x86_64-pc-windows-msvc/schannel/)
Expand Down
27 changes: 0 additions & 27 deletions appveyor.yml

This file was deleted.

2 changes: 1 addition & 1 deletion src/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -540,7 +540,7 @@ test suite with SCHANNEL_RS_SKIP_SERVER_TESTS=1.
}

fn local_root_store() -> CertStore {
if env::var("APPVEYOR").is_ok() {
if env::var("APPVEYOR").is_ok() || env::var("CI").is_ok() {
CertStore::open_local_machine("Root").unwrap()
} else {
CertStore::open_current_user("Root").unwrap()
Expand Down

0 comments on commit 703b8bb

Please sign in to comment.