Skip to content

Commit

Permalink
Re-add python3.12 and skip airflow test for this version
Browse files Browse the repository at this point in the history
  • Loading branch information
hussein-awala committed Jan 25, 2024
1 parent c57f605 commit 09ef943
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
fail-fast: true
matrix:
os: [ "ubuntu-latest", "macos-latest" ]
python-version: [ "3.8", "3.9", "3.10", "3.11" ]
python-version: [ "3.8", "3.9", "3.10", "3.11", "3.12" ]
runs-on: ${{ matrix.os }}
steps:
- name: Check out repository
Expand Down
4 changes: 4 additions & 0 deletions tests/airflow/test_operators.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,14 @@

from unittest import mock

import pytest
from spark_on_k8s.airflow.operators import SparkOnK8SOperator
from spark_on_k8s.client import ExecutorInstances, PodResources

from conftest import PYTHON_312


@pytest.mark.skipif(PYTHON_312, reason="Python 3.12 is not supported by Airflow")
class TestSparkOnK8SOperator:
@mock.patch("spark_on_k8s.client.SparkOnK8S.submit_app")
def test_execute(self, mock_submit_app):
Expand Down
5 changes: 5 additions & 0 deletions tests/conftest.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
from __future__ import annotations

import sys

PYTHON_312 = sys.version_info.major == 3 and sys.version_info.minor == 12

0 comments on commit 09ef943

Please sign in to comment.