From 1ff35e49f970786002527a4abd575c21ef2c3466 Mon Sep 17 00:00:00 2001 From: Jon Lamb Date: Sun, 15 Oct 2023 04:46:31 -0700 Subject: [PATCH] Add github action for robot framework tests --- .github/workflows/integration_tests.yml | 51 +++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 .github/workflows/integration_tests.yml diff --git a/.github/workflows/integration_tests.yml b/.github/workflows/integration_tests.yml new file mode 100644 index 0000000..90a8245 --- /dev/null +++ b/.github/workflows/integration_tests.yml @@ -0,0 +1,51 @@ +name: Integration Tests + +on: [push] + +env: + CARGO_TERM_COLOR: always + RENODE_CI_MODE: YES + +jobs: + robo_tests: + name: Roboot Framework Tests + runs-on: ubuntu-latest + steps: + - name: Checkout sources + uses: actions/checkout@v3 + + - name: Install renode + run: | + cd /opt + sudo wget --quiet --output-document renode.tar.gz https://builds.renode.io/renode-1.14.0+20231008gitebcb1b6b.linux-portable.tar.gz + sudo mkdir renode + sudo tar xf renode.tar.gz -C renode --strip-components 1 + sudo pip install -r /opt/renode/tests/requirements.txt + echo "PATH=/opt/renode:${PATH}" >> $GITHUB_ENV + + - name: Print renode version + run: renode --version + + - name: Install toolchain and components + run: rustup component add rustfmt clippy llvm-tools-preview + + - name: Install binutils, flip-link + run: cargo install cargo-binutils flip-link + + - name: Build bootloader + working-directory: bootloader + run: cargo build --release + + - name: Build firmware + working-directory: firmware + run: cargo build --release + + - name: Build CLI + working-directory: host_tools/air-gradient-cli + run: cargo build --release --all-features + + - name: Setup networking for tests + run: sudo ./renode/setup-network.sh & + + - name: Run tests + run: renode-test agp.robot