Skip to content

Commit 8dcccdd

Browse files
@CyberTailorarthurzam
authored andcommitted
fix TestRepoDirCheck
Replace 'Big5'-decodable byte string with another, which is non-decodable. Signed-off-by: Anna (cybertailor) Vyalkova <cyber+gentoo@sysrq.in> Signed-off-by: Arthur Zamarin <arthurzam@gentoo.org>
1 parent 27dbd7d commit 8dcccdd

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

tests/checks/test_repo.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ def test_ignored_root_dirs(self):
5858
bin_path = pjoin(self.repo.location, d, "foo")
5959
os.makedirs(os.path.dirname(bin_path))
6060
with open(bin_path, "wb") as f:
61-
f.write(b"\xd3\xad\xbe\xef")
61+
f.write(b"\xd3\x06\xf8\xef")
6262
self.assertNoReport(check, [])
6363

6464
def test_null_bytes(self):
@@ -74,7 +74,7 @@ def test_root_dir_binary(self):
7474
check = self.mk_check()
7575
bin_path = pjoin(self.repo.location, "foo")
7676
with open(bin_path, "wb") as f:
77-
f.write(b"\xd3\xad\xbe\xef")
77+
f.write(b"\xd3\x06\xf8\xef")
7878
r = self.assertReport(check, [])
7979
assert isinstance(r, repo.BinaryFile)
8080
assert r.path == "foo"
@@ -84,7 +84,7 @@ def test_ebuild_filesdir_binary(self):
8484
check = self.mk_check()
8585
filesdir = self.mk_pkg("dev-util/foo")
8686
with open(pjoin(filesdir, "foo"), "wb") as f:
87-
f.write(b"\xd3\xad\xbe\xef")
87+
f.write(b"\xd3\x06\xf8\xef")
8888
r = self.assertReport(check, [])
8989
assert isinstance(r, repo.BinaryFile)
9090
assert r.path == "dev-util/foo/files/foo"
@@ -96,7 +96,7 @@ def test_gitignore(self):
9696
distfiles = pjoin(self.repo.location, "distfiles")
9797
os.mkdir(distfiles)
9898
with open(pjoin(distfiles, "foo-0.tar.gz"), "wb") as f:
99-
f.write(b"\xd3\xad\xbe\xef")
99+
f.write(b"\xd3\x06\xf8\xef")
100100
r = self.assertReport(check, [])
101101
assert isinstance(r, repo.BinaryFile)
102102
assert "distfiles/foo-0.tar.gz" in str(r)

0 commit comments

Comments
 (0)