From 3b728b4a01d18a3689c81d5e69c849ff93f799ae Mon Sep 17 00:00:00 2001 From: Jakob Unterwurzacher Date: Wed, 12 Mar 2025 20:42:15 +0100 Subject: tests: matrix: fix TestFallocate Error was: --- FAIL: TestFallocate (0.01s) fallocate_test.go:172: Expected 8192 allocated bytes, have 12288 https://github.com/rfjakob/gocryptfs/pull/900 --- tests/matrix/fallocate_test.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/matrix/fallocate_test.go b/tests/matrix/fallocate_test.go index ade6415..44ea541 100644 --- a/tests/matrix/fallocate_test.go +++ b/tests/matrix/fallocate_test.go @@ -161,6 +161,10 @@ func TestFallocate(t *testing.T) { // xchacha has 24 byte ivs instead of 16. 8kiB are two blocks, so // 2x8=16 bytes more. plain = plain - 16 + } else if testcase.isSet("-aegis") { + // aegis256 has 32 byte ivs and mac instead of 16. 8kiB are two blocks, so + // 2x32=64 bytes more. + plain = plain - 64 } err = syscallcompat.Fallocate(fd, FALLOC_DEFAULT, 0, plain) if err != nil { -- cgit v1.2.3