mirror of
https://github.com/OCA/report-print-send.git
synced 2025-02-16 07:11:31 +02:00
[IMP] printer_zpl2: black, isort, prettier
This commit is contained in:
@@ -66,7 +66,9 @@ class PrintingLabelZpl2(models.Model):
|
|||||||
default=True,
|
default=True,
|
||||||
)
|
)
|
||||||
action_window_id = fields.Many2one(
|
action_window_id = fields.Many2one(
|
||||||
comodel_name="ir.actions.act_window", string="Action", readonly=True,
|
comodel_name="ir.actions.act_window",
|
||||||
|
string="Action",
|
||||||
|
readonly=True,
|
||||||
)
|
)
|
||||||
test_print_mode = fields.Boolean(string="Mode Print")
|
test_print_mode = fields.Boolean(string="Mode Print")
|
||||||
test_labelary_mode = fields.Boolean(string="Mode Labelary")
|
test_labelary_mode = fields.Boolean(string="Mode Labelary")
|
||||||
|
|||||||
@@ -134,7 +134,7 @@ class TestPrintingLabelZpl2(TransactionCase):
|
|||||||
)
|
)
|
||||||
|
|
||||||
def test_repeatable_component_label_fixed_contents(self):
|
def test_repeatable_component_label_fixed_contents(self):
|
||||||
""" Check contents of a repeatable label component
|
"""Check contents of a repeatable label component
|
||||||
|
|
||||||
Check that a fixed value is repeated each time
|
Check that a fixed value is repeated each time
|
||||||
"""
|
"""
|
||||||
@@ -193,7 +193,7 @@ class TestPrintingLabelZpl2(TransactionCase):
|
|||||||
)
|
)
|
||||||
|
|
||||||
def test_repeatable_component_label_iterable_contents(self):
|
def test_repeatable_component_label_iterable_contents(self):
|
||||||
""" Check contents of a repeatable label component
|
"""Check contents of a repeatable label component
|
||||||
|
|
||||||
Check that an iterable contents (list, tuple, etc.) is browsed
|
Check that an iterable contents (list, tuple, etc.) is browsed
|
||||||
If the repeat_count is higher than the value length, all values are
|
If the repeat_count is higher than the value length, all values are
|
||||||
@@ -247,7 +247,7 @@ class TestPrintingLabelZpl2(TransactionCase):
|
|||||||
)
|
)
|
||||||
|
|
||||||
def test_repeatable_component_label_iterable_offset(self):
|
def test_repeatable_component_label_iterable_offset(self):
|
||||||
""" Check contents of a repeatable label component with an offset
|
"""Check contents of a repeatable label component with an offset
|
||||||
|
|
||||||
Check that an iterable contents (list, tuple, etc.) is browsed
|
Check that an iterable contents (list, tuple, etc.) is browsed
|
||||||
If the repeat_count is higher than the value length, all values are
|
If the repeat_count is higher than the value length, all values are
|
||||||
@@ -777,7 +777,7 @@ class TestPrintingLabelZpl2(TransactionCase):
|
|||||||
)
|
)
|
||||||
|
|
||||||
def test_code49_barcode_label_contents_with_above(self):
|
def test_code49_barcode_label_contents_with_above(self):
|
||||||
""" Check contents of a code 49 barconde label
|
"""Check contents of a code 49 barconde label
|
||||||
with interpretation line above
|
with interpretation line above
|
||||||
"""
|
"""
|
||||||
label = self.new_label()
|
label = self.new_label()
|
||||||
|
|||||||
@@ -51,7 +51,7 @@ class TestWizardPrintRecordLabel(TransactionCase):
|
|||||||
cups.Connection().printFile.assert_called_once()
|
cups.Connection().printFile.assert_called_once()
|
||||||
|
|
||||||
def test_wizard_multiple_printers_and_labels(self):
|
def test_wizard_multiple_printers_and_labels(self):
|
||||||
""" Check that printer_id and label_id are not automatically filled
|
"""Check that printer_id and label_id are not automatically filled
|
||||||
when there are multiple possible values
|
when there are multiple possible values
|
||||||
"""
|
"""
|
||||||
self.env["printing.printer"].create(
|
self.env["printing.printer"].create(
|
||||||
@@ -85,7 +85,7 @@ class TestWizardPrintRecordLabel(TransactionCase):
|
|||||||
self.assertEqual(values.get("label_id", False), False)
|
self.assertEqual(values.get("label_id", False), False)
|
||||||
|
|
||||||
def test_wizard_multiple_labels_but_on_different_models(self):
|
def test_wizard_multiple_labels_but_on_different_models(self):
|
||||||
""" Check that label_id is automatically filled when there are multiple
|
"""Check that label_id is automatically filled when there are multiple
|
||||||
labels, but only one on the right model
|
labels, but only one on the right model
|
||||||
"""
|
"""
|
||||||
self.env["printing.label.zpl2"].create(
|
self.env["printing.label.zpl2"].create(
|
||||||
|
|||||||
Reference in New Issue
Block a user