Initial fork from theme-song-booth
This commit is contained in:
commit
99855b1212
33 changed files with 5723 additions and 0 deletions
30
.gitlab-ci.yml
Normal file
30
.gitlab-ci.yml
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
stages:
|
||||
- check
|
||||
- test
|
||||
|
||||
syntax:
|
||||
stage: check
|
||||
image: python:3.12-slim
|
||||
before_script:
|
||||
- pip install --no-cache-dir -r requirements.txt
|
||||
script:
|
||||
- python -m py_compile app.py models.py config.py init_db.py
|
||||
rules:
|
||||
- if: '$CI_PIPELINE_SOURCE == "push"'
|
||||
- if: '$CI_PIPELINE_SOURCE == "web"'
|
||||
|
||||
pytest:
|
||||
stage: test
|
||||
image: python:3.12-slim
|
||||
before_script:
|
||||
- pip install --no-cache-dir -r requirements.txt pytest
|
||||
script:
|
||||
- |
|
||||
if find . -type f \( -name "test_*.py" -o -name "*_test.py" \) | grep -q .; then
|
||||
pytest
|
||||
else
|
||||
echo "No tests found; skipping."
|
||||
fi
|
||||
rules:
|
||||
- if: '$CI_PIPELINE_SOURCE == "push"'
|
||||
- if: '$CI_PIPELINE_SOURCE == "web"'
|
||||
Loading…
Add table
Add a link
Reference in a new issue