Skip to content

Commit

Permalink
add test case for cli to improve test coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
noxan committed Nov 22, 2022
1 parent 8e85474 commit d568df2
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions tests/test_cli.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import pytest
from neuralprophet._version import __version__
from neuralprophet.__main__ import parser


def test_main_file(capsys):
with pytest.raises(SystemExit) as exit_info:
parser.parse_args(["--version"])

out, _ = capsys.readouterr()
assert "<ExceptionInfo SystemExit(0) tblen=8>" == str(exit_info)
assert __version__ in out

0 comments on commit d568df2

Please sign in to comment.