Debian Bug report logs - #355215
Better QuickCheck/HUnit integration

Package: ghc; Maintainer for ghc is Debian Haskell Group <pkg-haskell-maintainers@lists.alioth.debian.org>; Source for ghc is src:ghc.

Reported by: Daniel Burrows <dburrows@debian.org>

Date: Sat, 4 Mar 2006 05:18:52 UTC

Severity: wishlist

Tags: fixed-upstream

Done: Joachim Breitner <nomeata@debian.org>

Bug is archived. No further changes may be made.

Forwarded to http://hackage.haskell.org/trac/ghc/ticket/1594

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Ian Lynagh (wibble) <igloo@debian.org>:
Bug#355215; Package ghc6. Full text and rfc822 format available.

Acknowledgement sent to Daniel Burrows <dburrows@debian.org>:
New Bug report received and forwarded. Copy sent to Ian Lynagh (wibble) <igloo@debian.org>. Full text and rfc822 format available.

Message #5 received at submit@bugs.debian.org (full text, mbox):

From: Daniel Burrows <dburrows@debian.org>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: Better QuickCheck/HUnit integration
Date: Fri, 3 Mar 2006 21:11:53 -0800
[Message part 1 (text/plain, inline)]
Package: ghc6
Version: 6.4.1-1
Severity: wishlist

  Quickcheck and HUnit are both great tools for testing software, but it
seems to be rather difficult to make them work together.  In particular,
since the signature of all the quickCheck interface functions is some
variant on

Testable a => a -> IO ()

  the only way to find out whether a test succeeded or failed is to read
the terminal output.  It would be ideal if QuickCheck could generate HUnit
assertion failures when a test failed (maybe by expanding the Config
structure with "failure hooks"), but even just changing its signature
to either

Testable a => a -> IO Bool

  returning True for success, or (slightly more ambitiously)

Testable a => a -> IO (Maybe String)

  returning Nothing for success and an error message otherwise would be
enough to get basic integration working.

  Daniel

-- System Information:
Debian Release: testing/unstable
  APT prefers unstable
  APT policy: (500, 'unstable'), (1, 'experimental'), (1, 'unstable')
Architecture: i386 (i686)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.15-1-686
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)

Versions of packages ghc6 depends on:
ii  gcc                           4:4.0.2-2  The GNU C compiler
ii  haskell-utils                 1.6.0.1    Utilities used by the Debian Haske
ii  libc6                         2.3.6-3    GNU C Library: Shared libraries an
ii  libgmp3-dev                   4.1.4-11   Multiprecision arithmetic library 
ii  libgmp3c2                     4.1.4-11   Multiprecision arithmetic library
ii  libncurses5                   5.5-1      Shared libraries for terminal hand
ii  libreadline5                  5.1-6      GNU readline and history libraries
ii  libreadline5-dev              5.1-6      GNU readline and history libraries
ii  perl [perl5]                  5.8.8-2    Larry Wall's Practical Extraction 

ghc6 recommends no packages.

-- no debconf information
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Ian Lynagh (wibble) <igloo@debian.org>:
Bug#355215; Package ghc6. Full text and rfc822 format available.

Acknowledgement sent to Daniel Burrows <dburrows@debian.org>:
Extra info received and forwarded to list. Copy sent to Ian Lynagh (wibble) <igloo@debian.org>. Full text and rfc822 format available.

Message #10 received at 355215@bugs.debian.org (full text, mbox):

From: Daniel Burrows <dburrows@debian.org>
To: 355215@bugs.debian.org
Subject: Re: Bug#355215: Acknowledgement (Better QuickCheck/HUnit integration)
Date: Sat, 4 Mar 2006 09:24:53 -0800
[Message part 1 (text/plain, inline)]
  It seems that there's an undocumented interface into QuickCheck that
can be used to sort of integrate it with HUnit -- instead of spewing to
standard output for all tests, I got it to only toss exceptions when a
test failed or exhausted its argument space (see the attached module,
based on the QuickCheck code).  However, this is still not ideal; I'd
really rather be able to actually write HUnit tests within QuickCheck;
e.g.,

prop_Foo x = (0 * x) @?= 0

  Since QuickCheck requires you to use pure functions and the signature
of @?= is

  (Eq a, Show a) => a -> a -> IO ()

  this doesn't really work.  However, I think it would require a lot
more work to get this working with QuickCheck, and I suppose if your
properties are simple enough it should be easy to trace failures by hand.

  Daniel
[UnitCheck.hs (text/x-haskell, attachment)]
[signature.asc (application/pgp-signature, inline)]

Noted your statement that Bug has been forwarded to http://hackage.haskell.org/trac/ghc/ticket/1594. Request was from Ian Lynagh <ian@matrix.chaos.earth.li> to control@bugs.debian.org. (Tue, 07 Aug 2007 18:21:09 GMT) Full text and rfc822 format available.

Added tag(s) fixed-upstream. Request was from bts-link-upstream@lists.alioth.debian.org to control@bugs.debian.org. (Thu, 05 Aug 2010 16:36:34 GMT) Full text and rfc822 format available.

Bug reassigned from package 'ghc6' to 'ghc'. Request was from Joachim Breitner <nomeata@debian.org> to control@bugs.debian.org. (Wed, 30 Mar 2011 05:12:29 GMT) Full text and rfc822 format available.

Bug No longer marked as found in versions ghc6/6.4.1-1. Request was from Joachim Breitner <nomeata@debian.org> to control@bugs.debian.org. (Wed, 30 Mar 2011 05:12:29 GMT) Full text and rfc822 format available.

Reply sent to Joachim Breitner <nomeata@debian.org>:
You have taken responsibility. (Sat, 18 Jun 2011 19:09:11 GMT) Full text and rfc822 format available.

Notification sent to Daniel Burrows <dburrows@debian.org>:
Bug acknowledged by developer. (Sat, 18 Jun 2011 19:09:11 GMT) Full text and rfc822 format available.

Message #23 received at 355215-done@bugs.debian.org (full text, mbox):

From: Joachim Breitner <nomeata@debian.org>
To: 355215-done@bugs.debian.org
Subject: Probably not relevant any more
Date: Sat, 18 Jun 2011 21:05:04 +0200
[Message part 1 (text/plain, inline)]
Hi,

the comments on http://hackage.haskell.org/trac/ghc/ticket/1594 seem to
indicate that QuickCheck 2 has sufficient features, hence closing the
bug.

Greetings,
Joachim

-- 
Joachim "nomeata" Breitner
Debian Developer
  nomeata@debian.org | ICQ# 74513189 | GPG-Keyid: 4743206C
  JID: nomeata@joachim-breitner.de | http://people.debian.org/~nomeata
[signature.asc (application/pgp-signature, inline)]

Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Sun, 17 Jul 2011 07:32:56 GMT) Full text and rfc822 format available.

Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Thu Apr 17 22:14:35 2014; Machine Name: beach.debian.org

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