소스 검색

move another test to argparsing

Thomas Waldmann 2 년 전
부모
커밋
db0d15c182
2개의 변경된 파일8개의 추가작업 그리고 6개의 파일을 삭제
  1. 0 5
      src/borg/testsuite/archiver/__init__.py
  2. 8 1
      src/borg/testsuite/archiver/argparsing.py

+ 0 - 5
src/borg/testsuite/archiver/__init__.py

@@ -358,11 +358,6 @@ class ArchiverTestCaseBase(BaseTestCase):
 
 
 class ArchiverTestCase(ArchiverTestCaseBase):
-    def test_bad_filters(self):
-        self.cmd(f"--repo={self.repository_location}", "rcreate", RK_ENCRYPTION)
-        self.cmd(f"--repo={self.repository_location}", "create", "test", "input")
-        self.cmd(f"--repo={self.repository_location}", "delete", "--first", "1", "--last", "1", fork=True, exit_code=2)
-
     def test_do_not_mention_archive_if_you_can_not_find_repo(self):
         """https://github.com/borgbackup/borg/issues/6014"""
         output = self.cmd(

+ 8 - 1
src/borg/testsuite/archiver/argparsing.py

@@ -2,7 +2,14 @@ import argparse
 import pytest
 
 from ...helpers import parse_storage_quota
-from . import Archiver, RK_ENCRYPTION
+from . import ArchiverTestCaseBase, Archiver, RK_ENCRYPTION
+
+
+class ArchiverTestCase(ArchiverTestCaseBase):
+    def test_bad_filters(self):
+        self.cmd(f"--repo={self.repository_location}", "rcreate", RK_ENCRYPTION)
+        self.cmd(f"--repo={self.repository_location}", "create", "test", "input")
+        self.cmd(f"--repo={self.repository_location}", "delete", "--first", "1", "--last", "1", fork=True, exit_code=2)
 
 
 def test_get_args():