From f226b4c8b2496d673743965eac1bba6bcf716987 Mon Sep 17 00:00:00 2001 From: Zoe Roux Date: Thu, 12 May 2022 20:49:12 +0200 Subject: [PATCH] Add robot CI --- .github/workflows/build.yml | 2 +- .github/workflows/robot.yml | 33 +++++++++++++++++++++++++++++++++ 2 files changed, 34 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/robot.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 5fa0b972..a42ed529 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -54,7 +54,7 @@ jobs: LIBPATH: ${{env.LIBPATH}};C:\Program Files\FFmpeg\lib CFLAGS: -I/usr/local/include LDFLAGS: -L/usr/local/lib - run: dotnet publish -r ${{matrix.runtime}} -c Release -o dist ${{env.PROJECT}} + run: dotnet publish -r ${{matrix.runtime}} --self-contained -c Release -o dist ${{env.PROJECT}} - name: Compression output shell: bash run: | diff --git a/.github/workflows/robot.yml b/.github/workflows/robot.yml new file mode 100644 index 00000000..0fe10f6d --- /dev/null +++ b/.github/workflows/robot.yml @@ -0,0 +1,33 @@ +name: RobotTests +on: [push, pull_request, workflow_dispatch] + +jobs: + build: + runs-on: ubuntu-latest + if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository + steps: + - uses: actions/checkout@v2 + with: + submodules: recursive + + - name: Build the app + run: docker-compose build + + - name: Start the service + run: docker-compose up -d + + - name: Perform healthchecks + run: | + docker-compose ps -a + wget --retry-connrefused http://localhost:5000 # /healthcheck + + - name: Run robot tests + run: | + pip install -r tests/robot/requirements.txt + robot -d out tests/robot/ + + - uses: actions/upload-artifact@v2 + with: + name: results + path: out +