mirror of
https://github.com/DS4SD/docling.git
synced 2025-07-26 20:14:47 +00:00
add tests for CLI
Signed-off-by: Michele Dolfi <dol@zurich.ibm.com>
This commit is contained in:
parent
a34a402e66
commit
fca08ca355
20
tests/test_cli.py
Normal file
20
tests/test_cli.py
Normal file
@ -0,0 +1,20 @@
|
||||
from typer.testing import CliRunner
|
||||
|
||||
from docling.cli.main import app
|
||||
|
||||
runner = CliRunner()
|
||||
|
||||
|
||||
def test_cli_help():
|
||||
result = runner.invoke(app, ["--help"])
|
||||
assert result.exit_code == 0
|
||||
|
||||
|
||||
def test_cli_version():
|
||||
result = runner.invoke(app, ["--version"])
|
||||
assert result.exit_code == 0
|
||||
|
||||
|
||||
def test_cli_convert():
|
||||
result = runner.invoke(app, ["./tests/data/2305.03393v1-pg9.pdf"])
|
||||
assert result.exit_code == 0
|
Loading…
Reference in New Issue
Block a user