From 34eecf38b46f0400f22164b85570f711ec799007 Mon Sep 17 00:00:00 2001 From: Ajurna Date: Thu, 13 Jul 2023 20:42:16 +0000 Subject: [PATCH] Fixed downloading and scanning for volumes starting with a number (#41) * added test case for comics beginning with numbers * made small change to series regex to allow this to pass. also updated testcase. * Update comic series details in test cases The details of the 'Infinity Gauntlet' and '100 Bullets' comic series in the tests for the backend file handling were updated. This includes changing the issue range for both series. Changes were made to keep the tests in sync with the updated data specifications and enhance the test coverage. --------- Co-authored-by: Casvt <88994465+Casvt@users.noreply.github.com> --- backend/files.py | 2 +- tests/Tbackend/files.py | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/backend/files.py b/backend/files.py index 3f8447fe..94297087 100644 --- a/backend/files.py +++ b/backend/files.py @@ -53,7 +53,7 @@ issue_regex_6 = compile(r'(? Union[float, None]: diff --git a/tests/Tbackend/files.py b/tests/Tbackend/files.py index 4e6657f1..39154755 100644 --- a/tests/Tbackend/files.py +++ b/tests/Tbackend/files.py @@ -39,7 +39,13 @@ def test_general(self): 'Infinity Gauntlet #1 – 6 (1991-1992)': {'series': 'Infinity Gauntlet', 'year': 1991, 'volume_number': 1, 'special_version': None, 'issue_number': (1.0, 6.0), 'annual': False}, - 'Batman 026-050 (1945-1949) GetComics.INFO/Batman 048 52p ctc (08-1948) flattermann.cbr': + '1. Infinity Gauntlet #2 - 100 (1999-2009)': + {'series': 'Infinity Gauntlet', 'year': 1999, 'volume_number': 1, 'special_version': None, 'issue_number': (2.0, 100.0), 'annual': False}, + + '100 Bullets #1 - 101 (1999-2009)': + {'series': '100 Bullets', 'year': 1999, 'volume_number': 1, 'special_version': None, 'issue_number': (1.0, 101.0), 'annual': False}, + + 'Batman 026-050 (1945-1949) GetComics.INFO/Batman 048 52p ctc (08-1948) flattermann.cbr': {'series': 'Batman', 'year': 1945, 'volume_number': 1, 'special_version': None, 'issue_number': 48.0, 'annual': False} } self.run_cases(cases)