Reproduce scenario: Send Tcp Syn packet and forget #299
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
pull_request | |
env: | |
# `-D warnings` means any warnings emitted will cause build to fail | |
RUSTFLAGS: "-D warnings -C opt-level=z -C debuginfo=1" | |
X86_64_PC_WINDOWS_MSVC_OPENSSL_DIR: c:/vcpkg/installed/x64-windows | |
jobs: | |
checks: | |
name: Checks | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v1 | |
- name: Cmake | |
run: | | |
sudo apt-get install -y cmake | |
cmake --version | |
- name: Check formatting | |
uses: actions-rs/cargo@v1 | |
with: | |
command: fmt | |
args: --all -- --check | |
- name: Clippy | |
uses: actions-rs/cargo@v1 | |
with: | |
command: clippy | |
tests: | |
name: Tests | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ macos-latest, windows-latest, ubuntu-latest ] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v1 | |
- name: Cmake | |
if: matrix.os == 'ubuntu-latest' | |
run: | | |
sudo apt-get install -y cmake | |
cmake --version | |
- name: Install Protoc | |
uses: arduino/setup-protoc@v2 | |
with: | |
repo-token: ${{ secrets.GITHUB_TOKEN }} | |
version: "24.x" | |
- name: Unit tests | |
uses: actions-rs/cargo@v1 | |
with: | |
toolchain: ${{ env.rust_stable }} | |
command: test | |
args: --workspace | |
env: | |
RUST_BACKTRACE: 1 | |
integration_tests: | |
name: Integration Tests | |
needs: | |
- checks | |
- tests | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v1 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: '3.10' | |
- uses: Gr1N/setup-poetry@v8 | |
- name: Install dependencies | |
run: poetry install | |
working-directory: tests_integration | |
- name: Initialize the test suite | |
run: poetry run poe checks | |
working-directory: tests_integration | |
- name: Install tools | |
run: | | |
sudo apt-get install -y cmake | |
cmake --version | |
- name: Build relay server | |
uses: actions-rs/cargo@v1 | |
with: | |
toolchain: ${{ env.rust_stable }} | |
command: build | |
args: -p ya-relay-server --release | |
- name: Build http client | |
uses: actions-rs/cargo@v1 | |
with: | |
toolchain: ${{ env.rust_stable }} | |
command: build | |
args: -p ya-relay-client --example http_client --release | |
- name: Run test suite | |
run: poetry run pytest | |
working-directory: tests_integration |