feat: Establish CI pipeline for code quality checks and add unit tests for resolution preset logic.
This commit is contained in:
@@ -53,9 +53,13 @@ jobs:
|
||||
pip install torch --index-url https://download.pytorch.org/whl/cpu
|
||||
|
||||
- name: Validate Python syntax
|
||||
run: python -m py_compile __init__.py nodes.py presets.py resize.py
|
||||
run: |
|
||||
python -m py_compile __init__.py
|
||||
python -m py_compile nodes/__init__.py nodes/auto_size.py nodes/auto_size_latent.py
|
||||
python -m py_compile utils/presets.py utils/resize.py
|
||||
|
||||
- name: Test imports
|
||||
run: |
|
||||
python -c "import presets; print('✓ presets.py imports successfully')"
|
||||
python -c "import resize; print('✓ resize.py imports successfully')"
|
||||
python -c "from utils import presets; print('✓ presets.py imports successfully')"
|
||||
python -c "from utils import resize; print('✓ resize.py imports successfully')"
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import unittest
|
||||
from utils.presets import resolve_resolution, MODEL_SPECS
|
||||
from utils.presets import resolve_resolution
|
||||
|
||||
|
||||
class TestPresets(unittest.TestCase):
|
||||
|
||||
Reference in New Issue
Block a user