From 0a17ddb9d30d3090715d2486e16e6176e12d0946 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mateusz=20Sok=C3=B3=C5=82?= Date: Fri, 25 Apr 2025 23:13:43 +0000 Subject: [PATCH] CI test for finch-tensor --- .github/workflows/ci.yml | 86 +--------------------------------------- ci/test_array_api.sh | 2 +- 2 files changed, 3 insertions(+), 85 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e34182df..dc7c465e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -7,92 +7,10 @@ concurrency: cancel-in-progress: true jobs: - test: - strategy: - matrix: - os: ['ubuntu-latest'] - python: ['3.10', '3.11', '3.12'] - pip_opts: [''] - numba_boundscheck: [0] - include: - - os: macos-latest - python: '3.10' - - os: windows-latest - python: '3.10' - - os: ubuntu-latest - python: '3.10' - numba_boundscheck: 1 - - os: ubuntu-latest - python: '3.10' - pip_opts: 'numpy<2' - fail-fast: false - runs-on: ${{ matrix.os }} - env: - PYTHON_VERSION: ${{ matrix.python }} - NUMBA_BOUNDSCHECK: ${{ matrix.numba_boundscheck }} - steps: - - name: Checkout Repo - uses: actions/checkout@v4 - - uses: mamba-org/setup-micromamba@v2 - with: - environment-file: ci/environment.yml - init-shell: >- - bash - cache-environment: true - cache-downloads: true - post-cleanup: 'all' - create-args: >- - python=${{ matrix.python }} - ${{ matrix.pip_opts }} - - name: Install package - run: | - pip install -e '.[tests]' - - name: Run tests - run: ci/test_backends.sh - - uses: codecov/codecov-action@v5 - if: always() - with: - token: ${{ secrets.CODECOV_TOKEN }} - files: ./**/coverage*.xml - - examples: - runs-on: ubuntu-latest - steps: - - name: Checkout Repo - uses: actions/checkout@v4 - - name: Set up Python - uses: actions/setup-python@v5 - with: - python-version: '3.11' - cache: 'pip' - - name: Build and install Sparse - run: | - pip install -U setuptools wheel - pip install '.[finch]' scipy dask networkx graphblas-algorithms - - name: Run examples - run: ci/test_examples.sh - - notebooks: - runs-on: ubuntu-latest - steps: - - name: Checkout Repo - uses: actions/checkout@v4 - - name: Set up Python - uses: actions/setup-python@v5 - with: - python-version: '3.11' - cache: 'pip' - - name: Build and install Sparse - run: | - pip install -U setuptools wheel - pip install '.[notebooks]' - - name: Run notebooks - run: ci/test_notebooks.sh - array_api_tests: strategy: matrix: - backend: ['Numba', 'Finch'] + backend: ['Finch'] fail-fast: false env: ARRAY_API_TESTS_DIR: ${{ github.workspace }}/array-api-tests @@ -113,7 +31,7 @@ jobs: - name: Build and install Sparse run: | pip install -U setuptools wheel - pip install '.[finch]' + pip install finch-tensor - name: Run the test suite env: SPARSE_BACKEND: ${{ matrix.backend }} diff --git a/ci/test_array_api.sh b/ci/test_array_api.sh index 90864ef0..3bbb6bdb 100755 --- a/ci/test_array_api.sh +++ b/ci/test_array_api.sh @@ -6,4 +6,4 @@ source ci/clone_array_api_tests.sh if [ "${SPARSE_BACKEND}" = "Finch" ]; then python -c 'import finch' fi -ARRAY_API_TESTS_MODULE="sparse" pytest "$ARRAY_API_TESTS_DIR/array_api_tests/" -v -c "$ARRAY_API_TESTS_DIR/pytest.ini" --ci --max-examples=2 --derandomize --disable-deadline --disable-warnings -o xfail_strict=True -n auto --xfails-file ../sparse/ci/${SPARSE_BACKEND}-array-api-xfails.txt --skips-file ../sparse/ci/${SPARSE_BACKEND}-array-api-skips.txt +ARRAY_API_TESTS_MODULE="finch" pytest "$ARRAY_API_TESTS_DIR/array_api_tests/" -v -c "$ARRAY_API_TESTS_DIR/pytest.ini" --ci --max-examples=2 --derandomize --disable-deadline --disable-warnings -o xfail_strict=True -n auto --xfails-file ../sparse/ci/${SPARSE_BACKEND}-array-api-xfails.txt --skips-file ../sparse/ci/${SPARSE_BACKEND}-array-api-skips.txt