From 35b78373352a4bc0a07208c7dd186a5f5cf17530 Mon Sep 17 00:00:00 2001 From: yngrtc Date: Sun, 11 Feb 2024 10:52:59 -0800 Subject: [PATCH] add functional tests in github actions --- .github/workflows/ftests.yml | 37 ++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 .github/workflows/ftests.yml diff --git a/.github/workflows/ftests.yml b/.github/workflows/ftests.yml new file mode 100644 index 0000000..1d89afb --- /dev/null +++ b/.github/workflows/ftests.yml @@ -0,0 +1,37 @@ +name: ftests + +on: + push: + branches: [master] + pull_request: + branches: [master] + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +env: + CARGO_TERM_COLOR: always + +jobs: + ftests: + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v2 + with: + submodules: recursive + + - name: Set up Rust + uses: actions/setup-rust@v1 + with: + rust-version: stable + + - name: Run server + run: cargo run --release --package sfu --example chat -- -d --level info & echo $! > server_pid.txt + + - name: Run integration tests + run: cargo test --release + + - name: Shutdown server + run: kill -INT $(cat server_pid.txt) || true