1
0
Fork 0
mirror of https://github.com/borgbackup/borg.git synced 2024-12-26 01:37:20 +00:00

testsuite: archiver: increase hashing test bytes

A lower value results in the hash running too fast and the time being rounded down to 0.0, resulting in the test failing.
This commit is contained in:
Rayyan Ansari 2022-11-28 17:07:48 +00:00
parent 061397740c
commit d8e8247c6d

View file

@ -786,7 +786,7 @@ def extract_hashing_time(borg_create_output):
# Test case set up: create a repository and a file # Test case set up: create a repository and a file
self.cmd(f"--repo={self.repository_location}", "rcreate", "--encryption=none") self.cmd(f"--repo={self.repository_location}", "rcreate", "--encryption=none")
self.create_regular_file("testfile", contents=randbytes(15000000)) # more data might be needed for faster CPUs self.create_regular_file("testfile", contents=randbytes(50000000))
# Archive # Archive
result = self.cmd(f"--repo={self.repository_location}", "create", "--stats", "test_archive", self.input_path) result = self.cmd(f"--repo={self.repository_location}", "create", "--stats", "test_archive", self.input_path)
hashing_time = extract_hashing_time(result) hashing_time = extract_hashing_time(result)
@ -804,7 +804,7 @@ def extract_chunking_time(borg_create_output):
# Test case set up: create a repository and a file # Test case set up: create a repository and a file
self.cmd(f"--repo={self.repository_location}", "rcreate", RK_ENCRYPTION) self.cmd(f"--repo={self.repository_location}", "rcreate", RK_ENCRYPTION)
self.create_regular_file("testfile", contents=randbytes(10000000)) self.create_regular_file("testfile", contents=randbytes(50000000))
# Archive # Archive
result = self.cmd(f"--repo={self.repository_location}", "create", "--stats", "test_archive", self.input_path) result = self.cmd(f"--repo={self.repository_location}", "create", "--stats", "test_archive", self.input_path)
chunking_time = extract_chunking_time(result) chunking_time = extract_chunking_time(result)