From 2f0a2b5abf09122c5461585d0b27f8f4b50f47ab Mon Sep 17 00:00:00 2001 From: Oliver Date: Tue, 3 Jun 2025 10:32:18 +1000 Subject: [PATCH] Fix style (#9728) * Fix style * Adjust unit test --- src/backend/InvenTree/plugin/base/label/test_label_mixin.py | 5 +++-- src/backend/InvenTree/plugin/builtin/labels/label_sheet.py | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/backend/InvenTree/plugin/base/label/test_label_mixin.py b/src/backend/InvenTree/plugin/base/label/test_label_mixin.py index 73b522450f..1ecfea318d 100644 --- a/src/backend/InvenTree/plugin/base/label/test_label_mixin.py +++ b/src/backend/InvenTree/plugin/base/label/test_label_mixin.py @@ -76,12 +76,13 @@ class LabelMixinTests(PrintTestMixins, InvenTreeAPITestCase): # Should be available via the API now response = self.client.get(url, {'mixin': 'labels', 'active': True}) - self.assertEqual(len(response.data), 4) + self.assertEqual(len(response.data), 3) labels = [item['key'] for item in response.data] + self.assertIn('inventreelabel', labels) + self.assertIn('inventreelabelmachine', labels) self.assertIn('samplelabelprinter', labels) - self.assertIn('inventreelabelsheet', labels) def test_printing_process(self): """Test that a label can be printed.""" diff --git a/src/backend/InvenTree/plugin/builtin/labels/label_sheet.py b/src/backend/InvenTree/plugin/builtin/labels/label_sheet.py index 829d1130a1..497afd5ade 100644 --- a/src/backend/InvenTree/plugin/builtin/labels/label_sheet.py +++ b/src/backend/InvenTree/plugin/builtin/labels/label_sheet.py @@ -35,7 +35,7 @@ class LabelPrintingOptionsSerializer(serializers.Serializer): label=_('Skip Labels'), help_text=_('Skip this number of labels when printing label sheets'), min_value=0, - max_value=500 + max_value=500, ) border = serializers.BooleanField(