Applied, thanks!

I'll just do my usual whining about trailing whitespace ;-)

On Tue, Dec 23, 2008 at 09:42:43 +0100, Petr Rockai wrote:
> Tue Dec 23 08:36:42 CET 2008  Petr Rockai <[email protected]>
>   * Sort the list of tests that are run by cabal.
> 
> Tue Dec 23 09:08:11 CET 2008  Petr Rockai <[email protected]>
>   * Neatify "cabal test" option munging in Setup.lhs.
> 
> Tue Dec 23 09:37:42 CET 2008  Petr Rockai <[email protected]>
>   * Make it possible to run just specific tests from cabal commandline.
>   
>   All of `cabal test repair-corrupt bugs/newlines bugs/issue27.sh` should 
> work as
>   expected. The implementation is not very efficient, but seems to work fine.

Make it possible to run just specific tests from cabal commandline.
-------------------------------------------------------------------
I didn't actually review this patch, but did a koweylint.

> +testByPath x = do let [p, y] = splitDirectories x

Why is this guaranteed to work?

> +oneTest :: String -> IO ()
> +oneTest t = do let c = [t, t ++ ".sh"] ++ tryin "tests" t ++ tryin "bugs" t
> +                       ++ tryin "network" t
> +               run <- filterM doesFileExist c
> +               sequence_ [ do testByPath x | x <- take 1 run ]

Would mapM_ testByPath $ take 1 run be a better formulation here?
here?

> +    where tryin w t = [w </> t, w </> (t ++ ".sh")]

Perhaps:
  where tryin w t = [w </> t, w </> t <.> "sh"]

> +allTests :: TestKind -> [String] -> IO ()
> +allTests k s =
>      do test `mapM` repotypes
>         return ()

Hmm... Christian (who I think wrote this original code), I think this
could be written as mapM_ test repotypes.  I've added hlint to the hints
in http://wiki.darcs.net/index.html/CodingStyle

-- 
Eric Kow <http://www.nltg.brighton.ac.uk/home/Eric.Kow>
PGP Key ID: 08AC04F9

Attachment: signature.asc
Description: Digital signature

_______________________________________________
darcs-users mailing list
[email protected]
http://lists.osuosl.org/mailman/listinfo/darcs-users

Reply via email to