-
Notifications
You must be signed in to change notification settings - Fork 240
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2284df5
commit 7ac7593
Showing
2 changed files
with
66 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
name: MacOS | ||
permissions: read-all | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
pull_request_number: | ||
description: 'The pull request number' | ||
default: '' | ||
schedule: | ||
- cron: '0 0 * * 0' | ||
pull_request: | ||
|
||
jobs: | ||
precommit-common: | ||
runs-on: macos-latest | ||
steps: | ||
- uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6 | ||
with: | ||
lfs: true | ||
fetch-depth: 0 # Fetch full history to allow checking out any branch or PR | ||
- name: Fetch and Checkout the Pull Request Branch | ||
if: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.pull_request_number != '' }} | ||
run: | | ||
git fetch origin pull/${{ github.event.inputs.pull_request_number }}/head:pr-${{ github.event.inputs.pull_request_number }} | ||
git checkout pr-${{ github.event.inputs.pull_request_number }} | ||
- uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c # v5.0.0 | ||
with: | ||
python-version: "3.10" | ||
cache: pip | ||
- name: Install dependencies | ||
run: | | ||
pip install . | ||
pip install -r tests/common/requirements.txt | ||
- name: Print installed modules | ||
run: pip list | ||
- name: Run pre-commit | ||
run: pytest -n 2 -ra tests/common | ||
|
||
precommit-openvino: | ||
runs-on: macos-latest | ||
steps: | ||
- uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6 | ||
with: | ||
lfs: true | ||
fetch-depth: 0 # Fetch full history to allow checking out any branch or PR | ||
- name: Fetch and Checkout the Pull Request Branch | ||
if: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.pull_request_number != '' }} | ||
run: | | ||
git fetch origin pull/${{ github.event.inputs.pull_request_number }}/head:pr-${{ github.event.inputs.pull_request_number }} | ||
git checkout pr-${{ github.event.inputs.pull_request_number }} | ||
- uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c # v5.0.0 | ||
with: | ||
python-version: "3.10" | ||
cache: pip | ||
- name: Install dependencies | ||
run: | | ||
pip install . | ||
pip install -r tests/openvino/requirements.txt | ||
- name: Print installed modules | ||
run: pip list | ||
- name: Run pre-commit | ||
run: pytest -n 2 -ra tests/openvino --dist loadscope | ||
env: | ||
ONEDNN_MAX_CPU_ISA: AVX2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters