Skip to content

Commit 6f16664

Browse files
committed
CI: add Homebrew Python on macOS configuration
1 parent 2ef5862 commit 6f16664

File tree

1 file changed

+48
-0
lines changed

1 file changed

+48
-0
lines changed

.github/workflows/tests.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,3 +98,51 @@ jobs:
9898
flags: tests
9999
env_vars: PYTHON
100100
name: pyston
101+
102+
homebrew:
103+
runs-on: macos-latest
104+
env:
105+
FORCE_COLOR: true
106+
strategy:
107+
fail-fast: false
108+
matrix:
109+
python:
110+
- '3.7'
111+
- '3.8'
112+
- '3.9'
113+
- '3.10'
114+
- '3.11'
115+
116+
steps:
117+
- name: Checkout
118+
uses: actions/checkout@v2
119+
120+
- name: Install homebrew Python
121+
run: |
122+
brew reinstall python@${{ matrix.python }} || true
123+
brew link --overwrite python@${{ matrix.python }}
124+
echo /usr/local/opt/python@${{ matrix.python }}/libexec/bin/ >> $GITHUB_PATH
125+
126+
- run: |
127+
echo $PATH
128+
command -v python
129+
python --version
130+
131+
- name: Install
132+
run: python -m pip --disable-pip-version-check install .[test]
133+
134+
- name: Run tests
135+
run: >-
136+
python -m pytest --showlocals -vv --cov
137+
--cov-config setup.cfg
138+
--cov-report=xml:coverage-homebrew-${{ matrix.python }}.xml
139+
140+
- name: Send coverage report
141+
uses: codecov/codecov-action@v1
142+
if: ${{ always() }}
143+
env:
144+
PYTHON: homebrew-${{ matrix.python }}
145+
with:
146+
flags: tests
147+
env_vars: PYTHON
148+
name: homebrew-${{ matrix.python }}

0 commit comments

Comments
 (0)