Skip to content

Commit 9f09554

Browse files
authored
Manual Run + mothly tests
1 parent f7e1cb3 commit 9f09554

1 file changed

Lines changed: 5 additions & 9 deletions

File tree

.github/workflows/examples.yml

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,43 +1,39 @@
11
name: Test VFBquery Examples
2-
32
on:
4-
push:
5-
pull_request:
3+
push:
4+
pull_request:
5+
workflow_dispatch: # Enables manual triggering
6+
schedule:
7+
- cron: '0 0 1 * *' # Runs at 00:00 UTC on the 1st day of every month
68

79
jobs:
810
test-examples:
911
runs-on: ubuntu-latest
1012
steps:
1113
- name: Checkout repository
1214
uses: actions/checkout@v2
13-
1415
- name: Set up Python
1516
uses: actions/setup-python@v2
1617
with:
1718
python-version: 3.8
18-
1919
- name: Install dependencies
2020
run: |
2121
python -m pip install --upgrade pip
2222
pip install -r requirements.txt
2323
pip install deepdiff colorama
2424
pip install .
25-
2625
- name: Run examples from README.md
2726
run: |
2827
cat README.md | grep -e '```python' -e '```' -e '^[^`]*$' | sed -e '/^```python/,/^```/!d' -e '/^```/d' -e 's/\(vfb.[^)]*)\)/print(\1)/g' > test_examples.py
2928
cat test_examples.py
3029
python test_examples.py
31-
3230
- name: Parse README.md and generate test files
3331
run: |
3432
python -m src.test.readme_parser
3533
env:
3634
PYTHONPATH: ${{ github.workspace }}
37-
3835
- name: Run examples from README.md and compare JSON outputs
3936
run: |
4037
python -m src.test.test_examples_diff
4138
env:
4239
PYTHONPATH: ${{ github.workspace }}
43-

0 commit comments

Comments
 (0)