@@ -2,19 +2,59 @@ name: CI/CD Pipeline
22
33on :
44 push :
5- branches : [main, master ]
5+ branches : ["**" ]
66 tags : ['v*']
77
8+ env :
9+ PYTHON_VERSIONS : ' ["3.12", "3.13"]'
10+ OS_VERSIONS : ' ["ubuntu-latest", "windows-latest", "macos-latest"]'
11+
812
913jobs :
14+ test :
15+ name : Test Python ${{ matrix.python-version }} on ${{ matrix.os }}
16+ runs-on : ${{ matrix.os }}
17+ strategy :
18+ fail-fast : false
19+ matrix :
20+ os : ${{ fromJSON(env.OS_VERSIONS) }}
21+ python-version : ${{ fromJSON(env.PYTHON_VERSIONS) }}
22+ steps :
23+ - uses : actions/checkout@v4
24+
25+ - name : Set up Python ${{ matrix.python-version }}
26+ uses : actions/setup-python@v5
27+ with :
28+ python-version : ${{ matrix.python-version }}
29+
30+ - name : Install Poetry
31+ uses : snok/install-poetry@v1
32+ with :
33+ virtualenvs-create : true
34+ virtualenvs-in-project : true
35+
36+ - name : Install dependencies
37+ run : poetry install --with test --no-interaction --no-ansi
38+ shell : bash
39+
40+ - name : Run tests with coverage
41+ run : poetry run poe tests
42+
43+ - name : Upload coverage reports to Codecov
44+ if : matrix.python-version == '3.13' && matrix.os == 'ubuntu-latest'
45+ uses : codecov/codecov-action@v5
46+ with :
47+ token : ${{ secrets.CODECOV_TOKEN }}
48+ slug : ddc/pythonLogs
49+
1050 build :
1151 name : Build for Python ${{ matrix.python-version }} on ${{ matrix.os }}
1252 runs-on : ${{ matrix.os }}
1353 if : startsWith(github.ref, 'refs/tags/v')
1454 strategy :
1555 matrix :
16- os : [ubuntu-latest, windows-latest, macos-latest]
17- python-version : ["3.12", "3.13"]
56+ os : ${{ fromJSON(env.OS_VERSIONS) }}
57+ python-version : ${{ fromJSON(env.PYTHON_VERSIONS) }}
1858 steps :
1959 - uses : actions/checkout@v4
2060
3070 virtualenvs-in-project : true
3171
3272 - name : Install build dependencies only
33- run : poetry install --only main --no-interaction --no-ansi
73+ run : |
74+ if [[ "${{ matrix.os }}" == "windows-latest" ]]; then
75+ poetry install --only main --no-interaction --no-ansi -E mongodb -E mssql -E mysql -E oracle
76+ else
77+ poetry install --only main --no-interaction --no-ansi -E all
78+ fi
3479 shell : bash
3580
3681 - name : Build package with custom build script
0 commit comments