Package: check
Version: 0.9.5-3
Severity: normal

Hi,

when I have setup functions that fail (e.g., with fail_unless()), this
leads to broken statistics, e.g.:

-66%: Checks: 9, Failures: 15, Errors: 0

This comes from src/check_run.c:167:

  if ((tr->ctx == CK_CTX_TEST) || (tr->ctx == CK_CTX_TEARDOWN))
    sr->stats->n_checked++;

If we are still in CK_CTX_SETUP (==0), this iteration is not counted in
n_checked, but as failure, as can be seen above.

I propose removing the first quoted line, doing the "++"
unconditionally. I tried it and it works for me. I checked the Check
SVN, and the respective patch (rev. 182) "Fixed setup bug from forum,
failure in setup did not abort test in nofork mode." - explicitly should
fix a failure condition in setup. But the above described line is a bug,
IMHO.

Thanks for considering,

Roland

-- System Information:
Debian Release: lenny/sid
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: i386 (i686)

Kernel: Linux 2.6.24-rt1 (SMP w/1 CPU core; PREEMPT)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8) (ignored: LC_ALL 
set to en_GB.UTF-8)
Shell: /bin/sh linked to /bin/bash

-- no debconf information



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to