remove type comment where type is annotated

This commit is contained in:
Patrick Kanzler 2023-12-15 15:26:54 +01:00
parent 66a2e78e16
commit de8cf0086f
2 changed files with 3 additions and 3 deletions

View File

@ -20,7 +20,7 @@ except ImportError:
pass # noqa pass # noqa
import sys import sys
from . import config from . import config, escpos
from . import printer as escpos_printer_module from . import printer as escpos_printer_module
from . import version from . import version
@ -617,7 +617,7 @@ def main() -> None:
globals()[target_command](**command_arguments) globals()[target_command](**command_arguments)
def demo(printer, **kwargs) -> None: def demo(printer: escpos.Escpos, **kwargs) -> None:
"""Print demos. """Print demos.
Called when CLI is passed `demo`. This function Called when CLI is passed `demo`. This function

View File

@ -23,7 +23,7 @@ def test_raise_error_wrongly():
raise escpos.Error("This should raise an AttributeError.") raise escpos.Error("This should raise an AttributeError.")
def tests_raise_error(): def tests_raise_error() -> None:
"""raise error the right way""" """raise error the right way"""
with pytest.raises(escpos.exceptions.Error): with pytest.raises(escpos.exceptions.Error):
raise escpos.exceptions.Error("This should raise an error.") raise escpos.exceptions.Error("This should raise an error.")