77jobs :
88 unit-tests :
99 name : Test on Python v${{ matrix.python-version }}
10- runs-on : ubuntu-20 .04
10+ runs-on : ubuntu-24 .04
1111 strategy :
1212 matrix :
1313 include :
1414 - pipenv-version : ' 2022.4.8'
1515 python-version : ' 3.6'
16+ install-with : pyenv
1617 - pipenv-version : ' 2022.4.8'
1718 python-version : ' 3.7'
19+ install-with : pyenv
1820 - pipenv-version : ' 2022.4.8'
1921 python-version : ' 3.8'
22+ install-with : pyenv
2023 - pipenv-version : ' 2022.4.8'
2124 python-version : ' 3.9'
25+ install-with : pyenv
2226 - pipenv-version : ' 2023.2.4'
2327 python-version : ' 3.10'
28+ install-with : pyenv
2429 - pipenv-version : ' 2023.2.4'
2530 python-version : ' 3.11'
31+ install-with : pyenv
2632 - pipenv-version : ' 2024.4.0'
2733 python-version : ' 3.12'
2834 - pipenv-version : ' 2024.4.0'
2935 python-version : ' 3.13'
3036
3137 steps :
3238 - name : Checkout the repository
33- uses : actions/checkout@v2
39+ uses : actions/checkout@v4
3440 with :
3541 persist-credentials : false
3642
3743 - name : Install build essentials
3844 run : sudo apt-get --yes install build-essential
3945
40- - name : Set up Python
41- uses : actions/setup-python@v2
46+ - name : Install Python via pyenv
47+ if : matrix.install-with == 'pyenv'
48+ run : |
49+ export PYENV_GIT_TAG="v2.6.11"
50+ curl https://pyenv.run | bash
51+ export PATH="$HOME/.pyenv/bin:$PATH"
52+ eval "$(pyenv init -)"
53+ pyenv install ${{ matrix.python-version }}
54+ pyenv global ${{ matrix.python-version }}
55+ echo "$HOME/.pyenv/shims" >> $GITHUB_PATH
56+
57+ - name : Install Python via actions/setup-python
58+ if : matrix.install-with == null || matrix.install-with == 'actions/setup'
59+ uses : actions/setup-python@v6
4260 with :
4361 python-version : ${{ matrix.python-version }}
4462
@@ -57,15 +75,27 @@ jobs:
5775
5876 steps :
5977 - name : Checkout the repository
60- uses : actions/checkout@v2
78+ uses : actions/checkout@v4
6179 with :
6280 persist-credentials : false
6381
6482 - name : Install build essentials
6583 run : sudo apt-get --yes install build-essential
6684
67- - name : Set up Python
68- uses : actions/setup-python@v2
85+ - name : Install Python via pyenv
86+ if : matrix.install-with == 'pyenv'
87+ run : |
88+ export PYENV_GIT_TAG="v2.6.11"
89+ curl https://pyenv.run | bash
90+ export PATH="$HOME/.pyenv/bin:$PATH"
91+ eval "$(pyenv init -)"
92+ pyenv install ${{ matrix.python-version }}
93+ pyenv global ${{ matrix.python-version }}
94+ echo "$HOME/.pyenv/shims" >> $GITHUB_PATH
95+
96+ - name : Install Python via actions/setup-python
97+ if : matrix.install-with == null || matrix.install-with == 'actions/setup'
98+ uses : actions/setup-python@v6
6999
70100 - name : Install dependencies
71101 run : |
@@ -82,15 +112,27 @@ jobs:
82112
83113 steps :
84114 - name : Checkout the repository
85- uses : actions/checkout@v2
115+ uses : actions/checkout@v4
86116 with :
87117 persist-credentials : false
88118
89119 - name : Install build essentials
90120 run : sudo apt-get --yes install build-essential
91121
92- - name : Set up Python
93- uses : actions/setup-python@v2
122+ - name : Install Python via pyenv
123+ if : matrix.install-with == 'pyenv'
124+ run : |
125+ export PYENV_GIT_TAG="v2.6.11"
126+ curl https://pyenv.run | bash
127+ export PATH="$HOME/.pyenv/bin:$PATH"
128+ eval "$(pyenv init -)"
129+ pyenv install ${{ matrix.python-version }}
130+ pyenv global ${{ matrix.python-version }}
131+ echo "$HOME/.pyenv/shims" >> $GITHUB_PATH
132+
133+ - name : Install Python via actions/setup-python
134+ if : matrix.install-with == null || matrix.install-with == 'actions/setup'
135+ uses : actions/setup-python@v6
94136
95137 - name : Install dependencies
96138 run : |
@@ -115,15 +157,27 @@ jobs:
115157
116158 steps :
117159 - name : Checkout the repository
118- uses : actions/checkout@v2
160+ uses : actions/checkout@v4
119161 with :
120162 persist-credentials : false
121163
122164 - name : Install build essentials
123165 run : sudo apt-get --yes install build-essential
124166
125- - name : Set up Python
126- uses : actions/setup-python@v2
167+ - name : Install Python via pyenv
168+ if : matrix.install-with == 'pyenv'
169+ run : |
170+ export PYENV_GIT_TAG="v2.6.11"
171+ curl https://pyenv.run | bash
172+ export PATH="$HOME/.pyenv/bin:$PATH"
173+ eval "$(pyenv init -)"
174+ pyenv install ${{ matrix.python-version }}
175+ pyenv global ${{ matrix.python-version }}
176+ echo "$HOME/.pyenv/shims" >> $GITHUB_PATH
177+
178+ - name : Install Python via actions/setup-python
179+ if : matrix.install-with == null || matrix.install-with == 'actions/setup'
180+ uses : actions/setup-python@v6
127181
128182 - name : Install dependencies
129183 run : |
0 commit comments