From 6098811a00eae3831aa0fb8a00580eb72751d16e Mon Sep 17 00:00:00 2001 From: Ricardo Batista <138892976+rbatista191@users.noreply.github.com> Date: Fri, 27 Nov 2026 14:35:46 +0100 Subject: [PATCH] ci: run the tests on pull requests Add a CI workflow. It runs on each pull request and on each push to main. Branch protection on main will require its test checks. --- .github/workflows/ci.yml | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..d798891 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,27 @@ +# Runs the tests on each pull request and on each push to main. +# Branch protection on main requires the "test" checks of this workflow. +name: CI + +on: + pull_request: + push: + branches: [main] + +permissions: + contents: read + +jobs: + test: + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + # dify_plugin needs Python 3.12 or later. The Dify runner uses 3.12. + python-version: ["3.12", "3.15"] + steps: + - uses: actions/checkout@v7 + - uses: astral-sh/setup-uv@v7 + with: + python-version: ${{ matrix.python-version }} + - name: Run the tests + run: uv run --with-requirements requirements.txt --with pytest pytest tests