GNU bug report logs - #26709
Tests failing.

Previous Next

Package: coreutils;

Reported by: Григорий Резников <grikukan <at> mail.ru>

Date: Sat, 29 Apr 2017 16:55:02 UTC

Severity: normal

Done: Pádraig Brady <P <at> draigBrady.com>

Bug is archived. No further changes may be made.

Full log


Message #10 received at 26709-done <at> debbugs.gnu.org (full text, mbox):

From: Pádraig Brady <P <at> draigBrady.com>
To: Григорий Резников
 <grikukan <at> mail.ru>, 26709-done <at> debbugs.gnu.org
Subject: Re: bug#26709: Tests failing.
Date: Sat, 29 Apr 2017 20:59:24 -0700
On 29/04/17 01:37, Григорий Резников wrote:
> 
> I've tried to improve tests coverage, so I've built and ran tests using following commands:
> 
> ./configure CFLAGS="-g -fprofile-arcs -ftest-coverage"
> make -j8
> sudo make check -j8
> 
> After that I got FAIL on tests/mv/sticky-to-xpart and tests/rm/fail-2eperm.

Note there was a recently exposed race due to the extra steps to write the coverage files.
http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commitdiff;h=v8.26-36-gc95c0a0
But your case is a permissions issue as the two root tests in question operate
as the "nobody" user by default, and thus can't rewrite the coverage files.

Note I can reproduce with `make coverage` (which uses these settings):
https://github.com/coreutils/gnulib/blob/94386a13/top/maint.mk#L1483-L1508

To avoid the issue you can use the NON_ROOT_USERNAME setting as described at:
https://github.com/coreutils/coreutils/blob/7ea15a57/README#L116-L136

So a recipe to generate coverage is:

  $ make -j8 coverage
    Overall coverage rate:
      lines......: 81.4% (43883 of 53881 lines)
      functions..: 89.5% (2335 of 2608 functions)
  $ sudo make -j8 build-coverage NON_ROOT_USERNAME=$USER SUBDIRS=.
  $ make gen-coverage
    Overall coverage rate:
      lines......: 82.5% (44476 of 53881 lines)
      functions..: 90.9% (2370 of 2608 functions)

You can view the html report with:
  xdg-open doc/coverage/index.html

I've updated the HACKING instructions as above and pushed.

cheers,
Pádraig.




This bug report was last modified 8 years and 103 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.