summaryrefslogtreecommitdiffstats
path: root/.github
diff options
context:
space:
mode:
authorMarco Ieni <11428655+MarcoIeni@users.noreply.github.com>2020-11-28 20:48:40 +0100
committerGitHub <noreply@github.com>2020-11-28 14:48:40 -0500
commit64a9027f96ccca5990f85eefb0dbc0bbcb049272 (patch)
tree9f1a33c215db540020b984153c4ec4dd813cc51f /.github
parent4f167f4c7aff1d06d587e43187519f0590c5e49e (diff)
GitHub Continuous Integration: run tests on linux, mac and windows (#411)
* GitHub actions: add integration tests Signed-off-by: MarcoIeni <11428655+MarcoIeni@users.noreply.github.com> Co-authored-by: danyspin97 <oss@danyspin97.org> Co-authored-by: surveyor3 <samuelebertollo.sb@gmail.com> * GitHub actions: fix jobs names Signed-off-by: MarcoIeni <11428655+MarcoIeni@users.noreply.github.com> * GitHub actions: remove windows from integration tests Signed-off-by: MarcoIeni <11428655+MarcoIeni@users.noreply.github.com> Co-authored-by: danyspin97 <oss@danyspin97.org> Co-authored-by: surveyor3 <samuelebertollo.sb@gmail.com> * GitHub actions: fix target variable name Signed-off-by: MarcoIeni <11428655+MarcoIeni@users.noreply.github.com> Co-authored-by: danyspin97 <oss@danyspin97.org> Co-authored-by: surveyor3 <samuelebertollo.sb@gmail.com> Co-authored-by: danyspin97 <oss@danyspin97.org> Co-authored-by: surveyor3 <samuelebertollo.sb@gmail.com> Co-authored-by: Dan Davison <dandavison7@gmail.com>
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/ci.yml50
1 files changed, 46 insertions, 4 deletions
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index fa6e2e2a..49db2e8f 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -3,9 +3,19 @@ name: Continuous Integration
jobs:
- test:
- name: Test Suite
- runs-on: ubuntu-latest
+ unit_tests:
+ name: Unit tests
+ runs-on: ${{ matrix.os }}
+ strategy:
+ matrix:
+ os: [macos-latest, ubuntu-latest, windows-latest]
+ include:
+ - os: macos-latest
+ target: x86_64-apple-darwin
+ - os: ubuntu-latest
+ target: x86_64-unknown-linux-gnu
+ - os: windows-latest
+ target: x86_64-pc-windows-msvc
steps:
- name: Checkout repository
uses: actions/checkout@v2
@@ -19,8 +29,40 @@ jobs:
uses: actions-rs/cargo@v1
with:
command: test
+ args: --target ${{ matrix.target }} --verbose
+
+ integration_tests:
+ name: Integration tests
+ runs-on: ${{ matrix.os }}
+ strategy:
+ matrix:
+ os: [macos-latest, ubuntu-latest]
+ include:
+ - os: macos-latest
+ target: x86_64-apple-darwin
+ - os: ubuntu-latest
+ target: x86_64-unknown-linux-gnu
+ steps:
+ - name: Checkout repository
+ uses: actions/checkout@v2
+ - name: Install Rust
+ uses: actions-rs/toolchain@v1
+ with:
+ toolchain: stable
+ profile: minimal
+ override: true
+ - name: Build for release
+ uses: actions-rs/cargo@v1
+ with:
+ command: build
+ args: --target ${{ matrix.target }} --release
- name: End to end tests
- run: make end-to-end-test
+ run: |
+ DELTA_BIN=target/${{ matrix.target }}/release/delta
+ ./tests/test_raw_output_matches_git_on_full_repo_history $DELTA_BIN
+ ./tests/test_deprecated_options $DELTA_BIN > /dev/null
+ - name: Run executable
+ run: cargo run --release --target ${{ matrix.target }} -- < /dev/null
rustfmt:
name: Rustfmt