templates/python: fix type annotations
This commit is contained in:
@@ -1,15 +1,17 @@
|
||||
import sys
|
||||
|
||||
import pytest
|
||||
|
||||
import my_tool
|
||||
|
||||
|
||||
def test_no_args(capsys):
|
||||
def test_no_args(capsys: pytest.CaptureFixture) -> None:
|
||||
my_tool.my_cli()
|
||||
captured = capsys.readouterr()
|
||||
assert captured.out.startswith("usage:")
|
||||
|
||||
|
||||
def test_version(capsys, monkeypatch):
|
||||
def test_version(capsys: pytest.CaptureFixture, monkeypatch: pytest.MonkeyPatch) -> None:
|
||||
monkeypatch.setattr(sys, "argv", ["", "--version"])
|
||||
my_tool.my_cli()
|
||||
captured = capsys.readouterr()
|
||||
|
||||
Reference in New Issue
Block a user