test: add comprehensive test suite for schemas, tempo map, runner, and cli

This commit is contained in:
2026-11-02 10:05:05 +01:00
parent 169fd64064
commit ca1c116bd7
4 changed files with 424 additions and 0 deletions

25
tests/test_cli.py Normal file
View File

@ -0,0 +1,25 @@
"""Unit tests for songsplit CLI."""
from typer.testing import CliRunner
from songsplit.cli import app
runner = CliRunner()
def test_cli_help():
result = runner.invoke(app, ["--help"])
assert result.exit_code == 0
assert "Audio analysis pipeline decomposing songs into song packages" in result.stdout
assert "doctor" in result.stdout
assert "analyze" in result.stdout
def test_cli_doctor():
result = runner.invoke(app, ["doctor"])
assert result.exit_code == 0
# Rich table output is printed to stderr as configured in cli.py
output = result.stdout + result.stderr
assert "Python" in output
assert "ffmpeg" in output
assert "Model Cache" in output