1
0
mirror of https://github.com/python-escpos/python-escpos synced 2025-08-24 09:03:34 +00:00

split off dependencies for optional installation (#546)

* add inheritance diagrams to all printers and exceptions
* split off printer implementations into separate files
* add wrapper that thros RuntimeError if not importable
* add dependency check for lp
* add dependency check for pyserial
* added check for usability
* import Win32Raw
* include WIn32Raw in documentation
* enable all extras on tox
* update github workflow
This commit is contained in:
Patrick Kanzler
2023-08-17 01:37:50 +02:00
committed by GitHub
parent fbabd8ed88
commit 3177c8d411
20 changed files with 1115 additions and 627 deletions

View File

@@ -4,7 +4,7 @@
import pytest
import escpos.printer as printer
import escpos.escpos
@pytest.mark.parametrize(
@@ -48,7 +48,7 @@ import escpos.printer as printer
],
)
def test_check_valid_barcode(bctype, data):
assert printer.Escpos.check_barcode(bctype, data)
assert escpos.escpos.Escpos.check_barcode(bctype, data)
@pytest.mark.parametrize(
@@ -104,4 +104,4 @@ def test_check_valid_barcode(bctype, data):
],
)
def test_check_invalid_barcode(bctype, data):
assert not printer.Escpos.check_barcode(bctype, data)
assert not escpos.escpos.Escpos.check_barcode(bctype, data)