mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2025-08-26 01:16:16 +00:00
Upgrades black to v23, upgrades ruff
This commit is contained in:
@@ -114,7 +114,6 @@ simple_png2 = os.path.join(os.path.dirname(__file__), "examples", "no-text.png")
|
||||
|
||||
@override_settings(FILENAME_FORMAT="")
|
||||
class TestMigrateArchiveFiles(DirectoriesMixin, FileSystemAssertsMixin, TestMigrations):
|
||||
|
||||
migrate_from = "1011_auto_20210101_2340"
|
||||
migrate_to = "1012_fix_archive_files"
|
||||
|
||||
@@ -282,13 +281,11 @@ def fake_parse_wrapper(parser, path, mime_type, file_name):
|
||||
|
||||
@override_settings(FILENAME_FORMAT="")
|
||||
class TestMigrateArchiveFilesErrors(DirectoriesMixin, TestMigrations):
|
||||
|
||||
migrate_from = "1011_auto_20210101_2340"
|
||||
migrate_to = "1012_fix_archive_files"
|
||||
auto_migrate = False
|
||||
|
||||
def test_archive_missing(self):
|
||||
|
||||
Document = self.apps.get_model("documents", "Document")
|
||||
|
||||
doc = make_test_document(
|
||||
@@ -454,12 +451,10 @@ class TestMigrateArchiveFilesBackwards(
|
||||
FileSystemAssertsMixin,
|
||||
TestMigrations,
|
||||
):
|
||||
|
||||
migrate_from = "1012_fix_archive_files"
|
||||
migrate_to = "1011_auto_20210101_2340"
|
||||
|
||||
def setUpBeforeMigration(self, apps):
|
||||
|
||||
Document = apps.get_model("documents", "Document")
|
||||
|
||||
make_test_document(
|
||||
@@ -519,13 +514,11 @@ class TestMigrateArchiveFilesBackwardsWithFilenameFormat(
|
||||
|
||||
@override_settings(FILENAME_FORMAT="")
|
||||
class TestMigrateArchiveFilesBackwardsErrors(DirectoriesMixin, TestMigrations):
|
||||
|
||||
migrate_from = "1012_fix_archive_files"
|
||||
migrate_to = "1011_auto_20210101_2340"
|
||||
auto_migrate = False
|
||||
|
||||
def test_filename_clash(self):
|
||||
|
||||
Document = self.apps.get_model("documents", "Document")
|
||||
|
||||
self.clashA = make_test_document(
|
||||
@@ -554,7 +547,6 @@ class TestMigrateArchiveFilesBackwardsErrors(DirectoriesMixin, TestMigrations):
|
||||
)
|
||||
|
||||
def test_filename_exists(self):
|
||||
|
||||
Document = self.apps.get_model("documents", "Document")
|
||||
|
||||
self.clashA = make_test_document(
|
||||
|
Reference in New Issue
Block a user