From ca8c487323e3404cdae49e8578c31fa44937da13 Mon Sep 17 00:00:00 2001 From: Raul Zamora Date: Wed, 31 Aug 2022 11:27:30 +0200 Subject: [PATCH] add ci pipeline --- .github/workflows/ci.yaml | 49 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 .github/workflows/ci.yaml diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml new file mode 100644 index 00000000..40b9cbee --- /dev/null +++ b/.github/workflows/ci.yaml @@ -0,0 +1,49 @@ +name: Testing +on: + pull_request: + +jobs: + lint: + name: Lint + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Install dependencies + run: python3 -m pip install tox + - name: Run linters + run: tox -e lint + unit-test: + name: Unit tests + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Install dependencies + run: python -m pip install tox + - name: Run tests + run: tox -e unit + security-test: + name: Security tests + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Install dependencies + run: python -m pip install tox + - name: Run tests + run: tox -e security + integration-test: + name: Integration tests (microk8s) + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Setup operator environment + uses: charmed-kubernetes/actions-operator@main + with: + provider: microk8s + # This is needed until https://bugs.launchpad.net/juju/+bug/1977582 is fixed + bootstrap-options: "--agent-version 2.9.29" + - name: Run integration tests + run: tox -e integration \ No newline at end of file