Subject: bug#21280: test failures: nar, syscalls, containers

From: [email-masked] (Ludovic Courtès)
Date: Tue, 25 Aug 2015 00:07:44 +0200

Leo Famulari <[email-masked]> skribis:

> On Thu, Aug 20, 2015, at 06:02, Ludovic Courtès wrote:

[...]

>> I suspect the ‘nlink’ count on directories work differently on btrfs, or
>> something like that.

[...]

> %%%% Starting test nar  (Writing full log to "nar.log")
>
> ;;; (stat-output "./test-nar-7151" 1)
> tests/nar.scm:203: FAIL write-file + restore-file
>
> ;;; (stat-output "./test-nar-7151" 1)
> tests/nar.scm:220: FAIL write-file + restore-file with symlinks

Indeed, that confirms what I thought.

This looks like buggy or at least borderline behavior from Btrfs.
However, it seems that this ‘nlink’ test can be sidestepped altogether.

Could you apply this last patch and run:

  make check TESTS=tests/nar.scm

again?

If it works for you, I’ll just apply it.

Thanks!

Ludo’.

diff --git a/tests/nar.scm b/tests/nar.scm
index b8e50c7..58adb95 100644
--- a/tests/nar.scm
+++ b/tests/nar.scm
@@ -121,7 +121,7 @@
                     (lambda (name stat errno result)
                       (pk 'error name stat errno)
                       #f)
-                    (> (stat:nlink (stat output)) 2)
+                    #t
                     input
                     lstat))