From 0c32f05846a3bfa0495d56b24538cd307967483b Mon Sep 17 00:00:00 2001 From: shnmrt Date: Tue, 2 Sep 2025 15:33:25 +0200 Subject: [PATCH 1/2] fix: installation of duckdb before run the test --- .github/workflows/test-ci.yml | 57 ++++++++++++++++++----------------- 1 file changed, 29 insertions(+), 28 deletions(-) diff --git a/.github/workflows/test-ci.yml b/.github/workflows/test-ci.yml index 708dd3c..2fa2740 100644 --- a/.github/workflows/test-ci.yml +++ b/.github/workflows/test-ci.yml @@ -1,10 +1,10 @@ name: Test CI -on: +on: push: - branches: [ main ] + branches: [main] pull_request: - branches: [ main ] + branches: [main] jobs: test: @@ -16,32 +16,33 @@ jobs: python-version: ["3.11"] steps: - - name: Checkout code - uses: actions/checkout@v4 + - name: Checkout code + uses: actions/checkout@v4 - - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v5 - with: - python-version: ${{ matrix.python-version }} + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v5 + with: + python-version: ${{ matrix.python-version }} - - name: Install project and tools - run: | - python -m pip install --upgrade pip - pip install . - pip install coverage + - name: Install project and tools + run: | + python -m pip install --upgrade pip + python -c "import duckdb; duckdb.install_extension('spatial')" + pip install . + pip install coverage - - name: Run unittests with coverage - env: - PYTHONWARNINGS: ignore::ResourceWarning - PYTHONPATH: src - run: | - coverage run -m unittest discover -s test -p "test_*.py" - coverage report -m --omit="test/*" - coverage xml + - name: Run unittests with coverage + env: + PYTHONWARNINGS: ignore::ResourceWarning + PYTHONPATH: src + run: | + coverage run -m unittest discover -s test -p "test_*.py" + coverage report -m --omit="test/*" + coverage xml - - name: Upload coverage report - if: success() - uses: actions/upload-artifact@v4 - with: - name: coverage-report - path: coverage.xml \ No newline at end of file + - name: Upload coverage report + if: success() + uses: actions/upload-artifact@v4 + with: + name: coverage-report + path: coverage.xml From 92722a8b90157ffd53afb3e96ab87295e501c5fb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Murat=20=C5=9Eahin?= Date: Tue, 2 Sep 2025 15:39:42 +0200 Subject: [PATCH 2/2] Fix installation of spatial extension in CI workflow --- .github/workflows/test-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test-ci.yml b/.github/workflows/test-ci.yml index 2fa2740..0c71231 100644 --- a/.github/workflows/test-ci.yml +++ b/.github/workflows/test-ci.yml @@ -27,8 +27,8 @@ jobs: - name: Install project and tools run: | python -m pip install --upgrade pip - python -c "import duckdb; duckdb.install_extension('spatial')" pip install . + python -c "import duckdb; duckdb.install_extension('spatial')" pip install coverage - name: Run unittests with coverage