Skip to content

Commit 2c407b9

Browse files
committed
Scrollbar and unit tests
1 parent cd126f1 commit 2c407b9

23 files changed

Lines changed: 102328 additions & 50 deletions

.coverage

52 KB
Binary file not shown.

.github/workflows/ci.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Tests
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
9+
jobs:
10+
test:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- uses: actions/checkout@v4
15+
16+
- uses: actions/setup-python@v5
17+
with:
18+
python-version: "3.11"
19+
20+
- name: Install dependencies
21+
run: pip install -e ".[dev]"
22+
23+
- name: Run tests
24+
run: pytest --cov=core --cov-report=xml --cov-fail-under=80
25+
26+
- name: Upload coverage report
27+
uses: actions/upload-artifact@v4
28+
with:
29+
name: coverage-report
30+
path: coverage.xml

.gitignore

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
main.spec
55
stegcore.egg-info/
66
*__pycache__*
7-
/tests/
7+
*_qa.py*
88
*Zone.Identifier*
9-
.claude/
9+
.claude/
10+
*image_tests.py*
11+
*experiments/

pyproject.toml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,21 @@ stegcore = "main:main"
3030
# GUI: no console window (Windows: no cmd popup; Linux/macOS: detaches terminal)
3131
stegcore-gui = "main:main"
3232

33+
[project.optional-dependencies]
34+
dev = [
35+
"pytest>=8.0",
36+
"pytest-cov>=5.0",
37+
"Pillow>=10.0",
38+
"numpy>=1.26",
39+
]
40+
41+
[tool.pytest.ini_options]
42+
testpaths = ["tests"]
43+
addopts = "--cov=core --cov-report=html:htmlcov --cov-report=term-missing --cov-fail-under=90"
44+
45+
[tool.coverage.run]
46+
omit = ["core/utils.py"]
47+
3348
[tool.setuptools]
3449
# top-level .py files that are not inside a package directory
3550
py-modules = ["main", "cli"]

tests/assets/cover.bmp

3.12 MB
Binary file not shown.

tests/assets/cover.jpg

376 KB
Loading

tests/assets/cover.wav

6.9 MB
Binary file not shown.

tests/assets/cover_high.png

20.4 MB
Loading

tests/assets/cover_low.png

93.9 KB
Loading

tests/assets/cover_readonly.png

20.4 MB
Loading

0 commit comments

Comments
 (0)