Skip to content

Commit

Permalink
Add test framework
Browse files Browse the repository at this point in the history
  • Loading branch information
shssoichiro committed Oct 14, 2024
1 parent 01b29df commit f398232
Show file tree
Hide file tree
Showing 5 changed files with 37 additions and 2 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,6 @@ jobs:
pip install -r requirements-dev.txt
- name: Running ruff
run: ruff check vsscale
run: |
ruff check vsscale
ruff check tests
28 changes: 28 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: test

on: [push, pull_request]

jobs:
windows:
runs-on: windows-latest
strategy:
matrix:
versions:
- 68
python-version:
- '3.12'

steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python3 -m pip install --upgrade pip
pip install vapoursynth-portable==${{ matrix.versions }}
pip install -r requirements.txt
pip install -r requirements-dev.txt
- name: Running tests
run: pytest --cov-report=term-missing:skip-covered --cov=vsscale tests
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,9 @@ dmypy.json
# Local test file
*test*.py

# vscode folder
# Editor local configs
.vscode
.idea

# vsjet folder
.vsjet/
Expand Down
2 changes: 2 additions & 0 deletions pytest.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[pytest]
pythonpath = .
2 changes: 2 additions & 0 deletions requirements-dev.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
packaging>=24.0
pycodestyle>=2.11.1
pytest>=7.3.1
pytest-cov>=5.0.0
ruff>=0.6.5

0 comments on commit f398232

Please sign in to comment.