. e disable builds while troubleshooting #1019
This file contains hidden or 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
# This workflow will install Python dependencies, run tests and lint with a single version of Python | |
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions | |
name: python-tests | |
on: | |
push: | |
branches: | |
- '*' | |
pull_request: | |
branches: | |
- '*' | |
schedule: | |
- cron: '14 0 * * 3,6' # https://crontab.guru/#14_0_*_*_3,6 - "At 00:14 on Wednesday and Saturday." | |
jobs: | |
build: | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ubuntu-latest] | |
python-version: ["3.12"] | |
runs-on: ${{ matrix.os }} | |
if: false # Disable the build | |
steps: | |
- name: System Info | |
run: | | |
uname -a | |
- name: Check out ApprovalTests.cpp | |
uses: actions/checkout@v4 | |
with: | |
path: ApprovalTests/ApprovalTests.cpp | |
- name: Check out ApprovalTests.cpp.StarterProject | |
uses: actions/checkout@v4 | |
with: | |
repository: approvals/ApprovalTests.cpp.StarterProject | |
path: ApprovalTests/ApprovalTests.cpp.StarterProject | |
- name: Check out claremacrae fork of conan-center-index | |
uses: actions/checkout@v4 | |
with: | |
repository: claremacrae/conan-center-index | |
path: conan/conan-center-index-claremacrae | |
- name: Add upstream remote to conan-center-index-claremacrae, for testing dummy release | |
run: | | |
cd conan/conan-center-index-claremacrae | |
git remote add upstream https://github.com/conan-io/conan-center-index.git | |
- name: Check out llewellyn's fork of vcpkg | |
uses: actions/checkout@v4 | |
with: | |
repository: isidore/vcpkg | |
path: ApprovalTests/vcpkg | |
- name: Add upstream remote to vcpkg, for testing dummy release | |
run: | | |
cd ApprovalTests/vcpkg | |
git remote add upstream https://github.com/microsoft/vcpkg.git | |
- name: print dir | |
run: | | |
sudo apt-get install tree | |
tree -d -L 2 . | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- uses: r-lib/actions/setup-pandoc@v2 | |
with: | |
pandoc-version: '2.9.2.1' | |
- name: Install dependencies | |
run: | | |
cd ApprovalTests/ApprovalTests.cpp | |
cd build | |
./install_python_requirements.sh | |
- name: Check type hints | |
run: | | |
cd ApprovalTests/ApprovalTests.cpp | |
cd build | |
python3 -m pip install types-PyYAML | |
./check_type_hints.sh | |
- name: Lint with flake8 | |
run: | | |
cd ApprovalTests/ApprovalTests.cpp | |
./scripts/lint_python_with_flake8.sh | |
- name: Test build/ with pytest | |
run: | | |
cd ApprovalTests/ApprovalTests.cpp | |
cd build | |
./run_tests.sh | |
- name: Publish Test Report | |
uses: mikepenz/action-junit-report@v5 | |
if: always() | |
with: | |
report_paths: '**/build/test-reports/*.xml' | |
detailed_summary: true | |
- name: Test doc/sphinx with pytest | |
run: | | |
cd ApprovalTests/ApprovalTests.cpp | |
cd doc/sphinx/tests | |
python3 -m unittest discover -t ../.. --verbose | |
- name: Check preparing a release works | |
run: | | |
cd ApprovalTests/ApprovalTests.cpp/build | |
cat automation_hack_all_yesses.txt | ./prepare_minor_release.py |