Browse Source

move benchmark cmd tests to own module

Thomas Waldmann 2 years ago
parent
commit
245bdef4eb

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

@@ -1990,11 +1990,6 @@ class ArchiverTestCase(ArchiverTestCaseBase):
         self.cmd(f"--repo={self.repository_location}", "create", "test", "input")
         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)
         self.cmd(f"--repo={self.repository_location}", "delete", "--first", "1", "--last", "1", fork=True, exit_code=2)
 
 
-    def test_benchmark_crud(self):
-        self.cmd(f"--repo={self.repository_location}", "rcreate", RK_ENCRYPTION)
-        with environment_variable(_BORG_BENCHMARK_CRUD_TEST="YES"):
-            self.cmd(f"--repo={self.repository_location}", "benchmark", "crud", self.input_path)
-
     def test_config(self):
     def test_config(self):
         self.create_test_files()
         self.create_test_files()
         os.unlink("input/flagfile")
         os.unlink("input/flagfile")

+ 9 - 0
src/borg/testsuite/archiver/benchmark_cmd.py

@@ -0,0 +1,9 @@
+from ...constants import *  # NOQA
+from . import ArchiverTestCaseBase, RK_ENCRYPTION, environment_variable
+
+
+class ArchiverTestCase(ArchiverTestCaseBase):
+    def test_benchmark_crud(self):
+        self.cmd(f"--repo={self.repository_location}", "rcreate", RK_ENCRYPTION)
+        with environment_variable(_BORG_BENCHMARK_CRUD_TEST="YES"):
+            self.cmd(f"--repo={self.repository_location}", "benchmark", "crud", self.input_path)