-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4 from haskell-works/enable-doctest
Enable doctest
- Loading branch information
Showing
2 changed files
with
57 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{-# LANGUAGE CPP #-} | ||
|
||
#if MIN_VERSION_GLASGOW_HASKELL(8,4,4,0) | ||
{-# OPTIONS_GHC -F -pgmF doctest-discover #-} | ||
#else | ||
module Main where | ||
|
||
import qualified System.IO as IO | ||
|
||
main :: IO () | ||
main = IO.putStrLn "WARNING: doctest will not run on GHC versions earlier than 8.4.4" | ||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,33 +1,51 @@ | ||
name: hw-diagnostics | ||
version: 0.0.0.7 | ||
synopsis: Diagnostics library | ||
description: Please see README.md | ||
category: Profiling | ||
homepage: http://github.com/haskell-works/hw-diagnostics#readme | ||
bug-reports: https://github.com/haskell-works/hw-diagnostics/issues | ||
author: John Ky | ||
maintainer: newhoggy@gmail.com | ||
copyright: 2016 John Ky | ||
license: BSD3 | ||
license-file: LICENSE | ||
build-type: Simple | ||
cabal-version: >= 1.10 | ||
extra-source-files: | ||
README.md | ||
cabal-version: 2.4 | ||
|
||
name: hw-diagnostics | ||
version: 0.0.0.7 | ||
synopsis: Diagnostics library | ||
description: Please see README.md | ||
category: Profiling | ||
homepage: http://github.com/haskell-works/hw-diagnostics#readme | ||
bug-reports: https://github.com/haskell-works/hw-diagnostics/issues | ||
author: John Ky | ||
maintainer: newhoggy@gmail.com | ||
copyright: 2016-2019 John Ky | ||
license: BSD-3-Clause | ||
license-file: LICENSE | ||
build-type: Simple | ||
extra-source-files: README.md | ||
|
||
source-repository head | ||
type: git | ||
location: https://github.com/haskell-works/hw-diagnostics | ||
|
||
common base { build-depends: base >= 4 && < 5 } | ||
|
||
common doctest { build-depends: doctest >= 0.16.2 && < 0.17 } | ||
common doctest-discover { build-depends: doctest-discover >= 0.2 && < 0.3 } | ||
|
||
common hw-diagnostics | ||
build-depends: hw-diagnostics | ||
|
||
common config | ||
ghc-options: -Wall | ||
default-language: Haskell2010 | ||
|
||
library | ||
exposed-modules: | ||
HaskellWorks.Diagnostics | ||
HaskellWorks.Diagnostics.Time | ||
other-modules: | ||
Paths_hw_diagnostics | ||
hs-source-dirs: | ||
src | ||
ghc-options: -Wall | ||
build-depends: | ||
base >=4 && <5 | ||
default-language: Haskell2010 | ||
import: base, config | ||
exposed-modules: HaskellWorks.Diagnostics | ||
HaskellWorks.Diagnostics.Time | ||
other-modules: Paths_hw_diagnostics | ||
autogen-modules: Paths_hw_diagnostics | ||
hs-source-dirs: src | ||
|
||
test-suite doctest | ||
import: base, config | ||
, doctest | ||
, doctest-discover | ||
, hw-diagnostics | ||
type: exitcode-stdio-1.0 | ||
ghc-options: -threaded | ||
main-is: DoctestDriver.hs | ||
HS-Source-Dirs: doctest | ||
build-tool-depends: doctest-discover:doctest-discover |