gnu: Add confusion-mdl.
[jackhill/guix/guix.git] / gnu / packages / haskell-check.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2015 Paul van der Walt <paul@denknerd.org>
3 ;;; Copyright © 2015 Eric Bavier <bavier@member.fsf.org>
4 ;;; Copyright © 2015 Federico Beffa <beffa@fbengineering.ch>
5 ;;; Copyright © 2015, 2016, 2017, 2018 Ricardo Wurmus <rekado@elephly.net>
6 ;;; Copyright © 2016 Nils Gillmann <ng0@n0.is>
7 ;;; Copyright © 2016 David Craven <david@craven.ch>
8 ;;; Copyright © 2017 Danny Milosavljevic <dannym@scratchpost.org>
9 ;;; Copyright © 2017 rsiddharth <s@ricketyspace.net>
10 ;;; Copyright © 2017, 2018 Tobias Geerinckx-Rice <me@tobias.gr>
11 ;;; Copyright © 2018 Tonton <tonton@riseup.net>
12 ;;; Copyright © 2018 Arun Isaac <arunisaac@systemreboot.net>
13 ;;;
14 ;;; This file is part of GNU Guix.
15 ;;;
16 ;;; GNU Guix is free software; you can redistribute it and/or modify it
17 ;;; under the terms of the GNU General Public License as published by
18 ;;; the Free Software Foundation; either version 3 of the License, or (at
19 ;;; your option) any later version.
20 ;;;
21 ;;; GNU Guix is distributed in the hope that it will be useful, but
22 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
23 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24 ;;; GNU General Public License for more details.
25 ;;;
26 ;;; You should have received a copy of the GNU General Public License
27 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
28
29 (define-module (gnu packages haskell-check)
30 #:use-module (gnu packages)
31 #:use-module (gnu packages haskell)
32 #:use-module (gnu packages haskell-crypto)
33 #:use-module (guix build-system haskell)
34 #:use-module (guix download)
35 #:use-module ((guix licenses) #:prefix license:)
36 #:use-module (guix packages)
37 #:use-module (guix utils))
38
39 (define-public ghc-tasty-ant-xml
40 (package
41 (name "ghc-tasty-ant-xml")
42 (version "1.1.4")
43 (source
44 (origin
45 (method url-fetch)
46 (uri (string-append
47 "https://hackage.haskell.org/package/tasty-ant-xml/tasty-ant-xml-"
48 version
49 ".tar.gz"))
50 (sha256
51 (base32
52 "0v0gsb90kh6hwlgxbclzawsskywc6yf7n8xhiifia97l4y0yx2m8"))))
53 (build-system haskell-build-system)
54 (inputs
55 `(("ghc-generic-deriving" ,ghc-generic-deriving)
56 ("ghc-xml" ,ghc-xml)
57 ("ghc-mtl" ,ghc-mtl)
58 ("ghc-stm" ,ghc-stm)
59 ("ghc-tagged" ,ghc-tagged)
60 ("ghc-tasty" ,ghc-tasty)))
61 (home-page
62 "https://github.com/ocharles/tasty-ant-xml")
63 (synopsis
64 "Render tasty output to XML for Jenkins")
65 (description
66 "A tasty ingredient to output test results in XML, using the Ant
67 schema. This XML can be consumed by the Jenkins continuous integration
68 framework.")
69 (license license:bsd-3)))
70
71 (define-public ghc-tasty-smallcheck
72 (package
73 (name "ghc-tasty-smallcheck")
74 (version "0.8.1")
75 (source
76 (origin
77 (method url-fetch)
78 (uri (string-append
79 "https://hackage.haskell.org/package/tasty-smallcheck/tasty-smallcheck-"
80 version
81 ".tar.gz"))
82 (sha256
83 (base32
84 "1n66ngzllf3xrlqykwszlkwsi96n5nkm7xbpfq7774vpvfnafjri"))))
85 (build-system haskell-build-system)
86 (inputs
87 `(("ghc-tasty" ,ghc-tasty)
88 ("ghc-smallcheck" ,ghc-smallcheck)
89 ("ghc-async" ,ghc-async)
90 ("ghc-tagged" ,ghc-tagged)))
91 (home-page "https://documentup.com/feuerbach/tasty")
92 (synopsis "SmallCheck support for the Tasty test framework")
93 (description "This package provides SmallCheck support for the Tasty
94 Haskell test framework.")
95 (license license:bsd-3)))
96
97 (define-public ghc-tasty-quickcheck
98 (package
99 (name "ghc-tasty-quickcheck")
100 (version "0.8.4")
101 (source
102 (origin
103 (method url-fetch)
104 (uri (string-append
105 "https://hackage.haskell.org/package/tasty-quickcheck/"
106 "tasty-quickcheck-" version ".tar.gz"))
107 (sha256
108 (base32
109 "15rjxib5jmjq0hzj47x15kgp3awc73va4cy1pmpf7k3hvfv4qprn"))))
110 (build-system haskell-build-system)
111 (inputs
112 `(("ghc-quickcheck" ,ghc-quickcheck)
113 ("ghc-tagged" ,ghc-tagged)
114 ("ghc-tasty" ,ghc-tasty)
115 ("ghc-random" ,ghc-random)
116 ("ghc-ansi-terminal" ,ghc-ansi-terminal)
117 ("ghc-tasty-hunit" ,ghc-tasty-hunit)
118 ("ghc-pcre-light" ,ghc-pcre-light)))
119 (home-page "http://documentup.com/feuerbach/tasty")
120 (synopsis "QuickCheck support for the Tasty test framework")
121 (description "This package provides QuickCheck support for the Tasty
122 Haskell test framework.")
123 (license license:expat)))
124
125 (define-public ghc-tasty-golden
126 (package
127 (name "ghc-tasty-golden")
128 (version "2.3.1.1")
129 (source
130 (origin
131 (method url-fetch)
132 (uri (string-append
133 "https://hackage.haskell.org/package/tasty-golden/tasty-golden-"
134 version
135 ".tar.gz"))
136 (sha256
137 (base32
138 "0pcf5hsyp5mmbqn7krdm49jxpkjm6rb4j83j28f76h7q55dzm1wy"))))
139 (build-system haskell-build-system)
140 (inputs
141 `(("ghc-temporary" ,ghc-temporary)
142 ("ghc-tasty" ,ghc-tasty)
143 ("ghc-mtl" ,ghc-mtl)
144 ("ghc-optparse-applicative" ,ghc-optparse-applicative)
145 ("ghc-tagged" ,ghc-tagged)
146 ("ghc-async" ,ghc-async)
147 ("ghc-tasty-hunit" ,ghc-tasty-hunit)
148 ("ghc-temporary-rc" ,ghc-temporary-rc)))
149 (home-page
150 "https://github.com/feuerbach/tasty-golden")
151 (synopsis "Golden tests support for tasty")
152 (description
153 "This package provides support for 'golden testing'. A @dfn{golden test}
154 is an IO action that writes its result to a file. To pass the test, this
155 output file should be identical to the corresponding 'golden' file, which
156 contains the correct result for the test.")
157 (license license:expat)))
158
159 ;; This package builds `clock` without tests, since the tests rely on tasty
160 ;; and tasty-quickcheck, which in turn require clock to build.
161 (define ghc-clock-bootstrap
162 (package
163 (name "ghc-clock-bootstrap")
164 (version "0.5.1")
165 (source
166 (origin
167 (method url-fetch)
168 (uri (string-append
169 "https://hackage.haskell.org/package/"
170 "clock/"
171 "clock-" version ".tar.gz"))
172 (sha256
173 (base32 "1ncph7vi2q6ywwc8ysxl1ibw6i5dwfvln88ssfazk8jgpj4iyykw"))))
174 (build-system haskell-build-system)
175 (arguments `(#:tests? #f)) ;; Testing suite depends on tasty and
176 ;; tasty-quickcheck, which need clock to build.
177 (home-page "https://hackage.haskell.org/package/clock")
178 (synopsis "High-resolution clock for Haskell")
179 (description "A package for convenient access to high-resolution clock and
180 timer functions of different operating systems via a unified API.")
181 (license license:bsd-3)))
182
183 (define-public ghc-tasty
184 (package
185 (name "ghc-tasty")
186 (version "0.11.0.4")
187 (source
188 (origin
189 (method url-fetch)
190 (uri (string-append
191 "https://hackage.haskell.org/package/tasty/tasty-"
192 version
193 ".tar.gz"))
194 (sha256
195 (base32
196 "05pxjzgbgjdn7477xry0ssjrnmnsydqiq6nm6ck8n2da1baliqp0"))))
197 (build-system haskell-build-system)
198 (inputs
199 `(("ghc-stm" ,ghc-stm)
200 ("ghc-mtl" ,ghc-mtl)
201 ("ghc-tagged" ,ghc-tagged)
202 ("ghc-regex-tdfa" ,ghc-regex-tdfa)
203 ("ghc-regex-tdfa-rc" ,ghc-regex-tdfa-rc)
204 ("ghc-optparse-applicative" ,ghc-optparse-applicative)
205 ("ghc-unbounded-delays" ,ghc-unbounded-delays)
206 ("ghc-async" ,ghc-async)
207 ("ghc-ansi-terminal" ,ghc-ansi-terminal)
208 ("ghc-clock-bootstrap" ,ghc-clock-bootstrap)))
209 (home-page "http://documentup.com/feuerbach/tasty")
210 (synopsis "Modern and extensible testing framework")
211 (description "Tasty is a modern testing framework for Haskell. It lets
212 you combine your unit tests, golden tests, QuickCheck/SmallCheck properties,
213 and any other types of tests into a single test suite.")
214 (license license:expat)))
215
216 (define-public ghc-tasty-hunit
217 (package
218 (name "ghc-tasty-hunit")
219 (version "0.9.2")
220 (source
221 (origin
222 (method url-fetch)
223 (uri (string-append
224 "https://hackage.haskell.org/package/tasty-hunit/tasty-hunit-"
225 version
226 ".tar.gz"))
227 (sha256
228 (base32
229 "08qnxaw34wfnzi9irs1jd4d0zczqm3k5ffkd4zwhkz0dflmgq7mf"))))
230 (build-system haskell-build-system)
231 (inputs
232 `(("ghc-tasty" ,ghc-tasty)))
233 (home-page "http://documentup.com/feuerbach/tasty")
234 (synopsis "HUnit support for the Tasty test framework")
235 (description "This package provides HUnit support for the Tasty Haskell
236 test framework.")
237 (license license:expat)))
238
239 (define-public ghc-tasty-kat
240 (package
241 (name "ghc-tasty-kat")
242 (version "0.0.3")
243 (source (origin
244 (method url-fetch)
245 (uri (string-append "https://hackage.haskell.org/package/"
246 "tasty-kat/tasty-kat-" version ".tar.gz"))
247 (sha256
248 (base32
249 "14yvlpli6cv6bn3kh8mlfp4x1l6ns4fvmfv6hmj75cvxyzq029d7"))))
250 (build-system haskell-build-system)
251 (inputs
252 `(("ghc-tasty" ,ghc-tasty)
253 ("ghc-mtl" ,ghc-mtl)
254 ("ghc-tasty-quickcheck" ,ghc-tasty-quickcheck)
255 ("ghc-tasty-hunit" ,ghc-tasty-hunit)))
256 (home-page "https://github.com/vincenthz/tasty-kat")
257 (synopsis "Known Answer Tests (KAT) framework for tasty")
258 (description
259 "This package provides a @dfn{Known Answer Tests} (KAT) framework for
260 tasty.")
261 (license license:expat)))
262
263 (define-public ghc-tasty-th
264 (package
265 (name "ghc-tasty-th")
266 (version "0.1.4")
267 (source
268 (origin
269 (method url-fetch)
270 (uri (string-append
271 "https://hackage.haskell.org/package/tasty-th/tasty-th-"
272 version ".tar.gz"))
273 (sha256
274 (base32
275 "0dff9si8i1qp0s7p4hlk0l29vq7wxfglw6mvlgmld43h7rllv88q"))))
276 (build-system haskell-build-system)
277 (inputs
278 `(("ghc-tasty" ,ghc-tasty)))
279 (home-page "https://github.com/bennofs/tasty-th")
280 (synopsis "Automatically generate tasty TestTrees")
281 (description
282 "Tasty-th automatically generates tasty TestTrees from functions of the
283 current module, using TemplateHaskell. This is a fork the original
284 test-framework-th package, modified to work with tasty instead of
285 test-framework.")
286 (license license:bsd-3)))
287
288 (define-public ghc-tasty-rerun
289 (package
290 (name "ghc-tasty-rerun")
291 (version "1.1.8")
292 (source (origin
293 (method url-fetch)
294 (uri (string-append
295 "https://hackage.haskell.org/package/tasty-rerun/"
296 "tasty-rerun-" version ".tar.gz"))
297 (sha256
298 (base32
299 "0yg8cicfn3qaazvp4rbanzy3dyk95k3y1kkd4bykvkl9v4076788"))))
300 (build-system haskell-build-system)
301 (inputs
302 `(("ghc-mtl" ,ghc-mtl)
303 ("ghc-optparse-applicative" ,ghc-optparse-applicative)
304 ("ghc-reducers" ,ghc-reducers)
305 ("ghc-split" ,ghc-split)
306 ("ghc-stm" ,ghc-stm)
307 ("ghc-tagged" ,ghc-tagged)
308 ("ghc-tasty" ,ghc-tasty)))
309 (home-page "https://github.com/ocharles/tasty-rerun")
310 (synopsis "Run tests by filtering the test tree")
311 (description "This package adds the ability to run tests by filtering the
312 test tree based on the result of a previous test run. You can use this to run
313 only those tests that failed in the last run, or to only run the tests that have
314 been added since previous test run.")
315 (license license:bsd-3)))
316
317 (define-public ghc-tasty-expected-failure
318 (package
319 (name "ghc-tasty-expected-failure")
320 (version "0.11.0.4")
321 (source
322 (origin
323 (method url-fetch)
324 (uri (string-append "https://hackage.haskell.org/package/"
325 "tasty-expected-failure/tasty-expected-failure-"
326 version ".tar.gz"))
327 (sha256
328 (base32
329 "0r555f18d2gj96pjyc13chn1nxaxl81am4xgip3mvvjhw8s5mva1"))))
330 (build-system haskell-build-system)
331 (inputs
332 `(("ghc-tagged" ,ghc-tagged)
333 ("ghc-tasty" ,ghc-tasty)))
334 (home-page "http://github.com/nomeata/tasty-expected-failure")
335 (synopsis "Mark tasty tests as failure expected")
336 (description
337 "With the function @code{Test.Tasty.ExpectedFailure.expectFail} in the
338 provided module @code{Test.Tasty.ExpectedFailure}, you can mark that you
339 expect test cases to fail, and not to pass. This can be used for test-driven
340 development.")
341 (license license:expat)))
342
343 (define-public ghc-quickcheck-instances
344 (package
345 (name "ghc-quickcheck-instances")
346 (version "0.3.18")
347 (source
348 (origin
349 (method url-fetch)
350 (uri (string-append
351 "https://hackage.haskell.org/package/"
352 "quickcheck-instances/quickcheck-instances-"
353 version ".tar.gz"))
354 (sha256
355 (base32
356 "1bh1pzz5fdcqvzdcirqxna6fnjms02min5md716299g5niz46w55"))))
357 (build-system haskell-build-system)
358 (arguments
359 `(#:configure-flags (list "--allow-newer=base-compat")))
360 (inputs
361 `(("ghc-quickcheck" ,ghc-quickcheck)
362 ("ghc-base-compat" ,ghc-base-compat)
363 ("ghc-case-insensitive" ,ghc-case-insensitive)
364 ("ghc-hashable" ,ghc-hashable)
365 ("ghc-old-time" ,ghc-old-time)
366 ("ghc-scientific" ,ghc-scientific)
367 ("ghc-tagged" ,ghc-tagged)
368 ("ghc-text" ,ghc-text)
369 ("ghc-transformers-compat" ,ghc-transformers-compat)
370 ("ghc-unordered-containers" ,ghc-unordered-containers)
371 ("ghc-uuid-types" ,ghc-uuid-types)
372 ("ghc-vector" ,ghc-vector)))
373 (home-page "https://github.com/aslatter/qc-instances")
374 (synopsis "Common quickcheck instances")
375 (description "This package provides QuickCheck instances for types
376 provided by the Haskell Platform.")
377 (license license:bsd-3)))
378
379 (define-public ghc-quickcheck-unicode
380 (package
381 (name "ghc-quickcheck-unicode")
382 (version "1.0.1.0")
383 (source
384 (origin
385 (method url-fetch)
386 (uri (string-append
387 "https://hackage.haskell.org/package/quickcheck-unicode/"
388 "quickcheck-unicode-" version ".tar.gz"))
389 (sha256
390 (base32
391 "0s43s1bzbg3gwsjgm7fpyksd1339f0m26dlw2famxwyzgvm0a80k"))))
392 (build-system haskell-build-system)
393 (inputs `(("ghc-quickcheck" ,ghc-quickcheck)))
394 (home-page
395 "https://github.com/bos/quickcheck-unicode")
396 (synopsis "Generator functions Unicode-related tests")
397 (description "This package provides generator and shrink functions for
398 testing Unicode-related software.")
399 (license license:bsd-3)))
400
401 (define-public ghc-quickcheck-io
402 (package
403 (name "ghc-quickcheck-io")
404 (version "0.2.0")
405 (source
406 (origin
407 (method url-fetch)
408 (uri (string-append
409 "https://hackage.haskell.org/package/quickcheck-io/quickcheck-io-"
410 version
411 ".tar.gz"))
412 (sha256
413 (base32
414 "08k4v7pkgjf30pv5j2dfv1gqv6hclxlniyq2sps8zq4zswcr2xzv"))))
415 (build-system haskell-build-system)
416 (inputs
417 `(("ghc-quickcheck" ,ghc-quickcheck)
418 ("ghc-hunit" ,ghc-hunit)))
419 (home-page
420 "https://github.com/hspec/quickcheck-io#readme")
421 (synopsis "Use HUnit assertions as QuickCheck properties")
422 (description "This package provides an orphan instance that allows you to
423 use HUnit assertions as QuickCheck properties.")
424 (license license:expat)))
425
426 (define-public ghc-quickcheck
427 (package
428 (name "ghc-quickcheck")
429 (version "2.10.1")
430 (outputs '("out" "doc"))
431 (source
432 (origin
433 (method url-fetch)
434 (uri (string-append
435 "https://hackage.haskell.org/package/QuickCheck/QuickCheck-"
436 version
437 ".tar.gz"))
438 (sha256
439 (base32
440 "1rfmns3lj3hl93k1jws85ajkkw7z9ll8cw292n9m7zald1w5dfqx"))))
441 (build-system haskell-build-system)
442 (arguments
443 `(#:tests? #f ; FIXME: currently missing libraries used for tests.
444 #:configure-flags '("-f base4")))
445 (inputs
446 `(("ghc-random" ,ghc-random)
447 ("ghc-tf-random" ,ghc-tf-random)))
448 (home-page "https://github.com/nick8325/quickcheck")
449 (synopsis "Automatic testing of Haskell programs")
450 (description
451 "QuickCheck is a library for random testing of program properties. The
452 programmer provides a specification of the program, in the form of properties
453 which functions should satisfy, and QuickCheck then tests that the properties
454 hold in a large number of randomly generated cases. Specifications are
455 expressed in Haskell, using combinators defined in the QuickCheck library.")
456 (license license:bsd-3)))
457
458 (define-public ghc-quickcheck-2.9
459 (package
460 (inherit ghc-quickcheck)
461 (name "ghc-quickcheck")
462 (version "2.9.2")
463 (source (origin
464 (method url-fetch)
465 (uri (string-append "https://hackage.haskell.org/package/QuickCheck-2.9.2/QuickCheck-"
466 version ".tar.gz"))
467 (sha256
468 (base32
469 "119np67qvx8hyp9vkg4gr2wv3lj3j6ay2vl4hxspkg43ymb1cp0m"))))))
470
471 (define-public ghc-quickcheck-latest
472 (package (inherit ghc-quickcheck)
473 (version "2.11.3")
474 (source
475 (origin
476 (method url-fetch)
477 (uri (string-append
478 "https://hackage.haskell.org/package/QuickCheck/QuickCheck-"
479 version
480 ".tar.gz"))
481 (sha256
482 (base32
483 "0xhqk35fkzlbjcqbabg6962jkv8d688nzmz7ng4bm84x2d95d328"))))))
484
485 (define-public ghc-test-framework
486 (package
487 (name "ghc-test-framework")
488 (version "0.8.1.1")
489 (source
490 (origin
491 (method url-fetch)
492 (uri (string-append "https://hackage.haskell.org/package/test-framework/"
493 "test-framework-" version ".tar.gz"))
494 (sha256
495 (base32
496 "0wxjgdvb1c4ykazw774zlx86550848wbsvgjgcrdzcgbb9m650vq"))))
497 (build-system haskell-build-system)
498 (arguments
499 `(#:configure-flags (list "--allow-newer=time")))
500 (native-inputs
501 `(("ghc-hunit" ,ghc-hunit)
502 ("ghc-quickcheck" ,ghc-quickcheck)))
503 (inputs
504 `(("ghc-ansi-terminal" ,ghc-ansi-terminal)
505 ("ghc-ansi-wl-pprint" ,ghc-ansi-wl-pprint)
506 ("ghc-hostname" ,ghc-hostname)
507 ("ghc-old-locale" ,ghc-old-locale)
508 ("ghc-random" ,ghc-random)
509 ("ghc-regex-posix" ,ghc-regex-posix)
510 ("ghc-xml" ,ghc-xml)
511 ("ghc-libxml" ,ghc-libxml)))
512 (home-page "https://batterseapower.github.io/test-framework/")
513 (synopsis "Framework for running and organising tests")
514 (description
515 "This package allows tests such as QuickCheck properties and HUnit test
516 cases to be assembled into test groups, run in parallel (but reported in
517 deterministic order, to aid diff interpretation) and filtered and controlled
518 by command line options. All of this comes with colored test output, progress
519 reporting and test statistics output.")
520 (license license:bsd-3)))
521
522 (define-public ghc-test-framework-hunit
523 (package
524 (name "ghc-test-framework-hunit")
525 (version "0.3.0.2")
526 (source
527 (origin
528 (method url-fetch)
529 (uri (string-append "https://hackage.haskell.org/package/"
530 "test-framework-hunit/test-framework-hunit-"
531 version ".tar.gz"))
532 (sha256
533 (base32
534 "1y0b6vg8nfm43v90lxxcydhi6qlxhfy4vpxbzm5ic2w55bh8xjwm"))))
535 (build-system haskell-build-system)
536 ;; The official revision of the cabal file allows for HUnit lower than 1.7
537 (arguments
538 `(#:configure-flags (list "--allow-newer=HUnit")))
539 (inputs
540 `(("ghc-extensible-exceptions" ,ghc-extensible-exceptions)
541 ("ghc-hunit" ,ghc-hunit)
542 ("ghc-test-framework" ,ghc-test-framework)))
543 (home-page "https://batterseapower.github.io/test-framework/")
544 (synopsis "HUnit support for test-framework")
545 (description
546 "This package provides HUnit support for the test-framework package.")
547 (license license:bsd-3)))
548
549 (define-public ghc-test-framework-quickcheck2
550 (package
551 (name "ghc-test-framework-quickcheck2")
552 (version "0.3.0.4")
553 (source
554 (origin
555 (method url-fetch)
556 (uri (string-append "https://hackage.haskell.org/package/"
557 "test-framework-quickcheck2/"
558 "test-framework-quickcheck2-" version ".tar.gz"))
559 (sha256
560 (base32
561 "0vj834337r6jzr3258cv68ly2sv5999mklpsrfngyk51kywsyqyp"))))
562 (build-system haskell-build-system)
563 (inputs
564 `(("ghc-extensible-exceptions" ,ghc-extensible-exceptions)
565 ("ghc-quickcheck" ,ghc-quickcheck)
566 ("ghc-random" ,ghc-random)
567 ("ghc-test-framework" ,ghc-test-framework)))
568 (home-page "https://batterseapower.github.io/test-framework/")
569 (synopsis "QuickCheck2 support for test-framework")
570 (description
571 "This packages provides QuickCheck2 support for the test-framework
572 package.")
573 (license license:bsd-3)))
574
575 (define-public ghc-test-framework-th
576 (package
577 (name "ghc-test-framework-th")
578 (version "0.2.4")
579 (source
580 (origin
581 (method url-fetch)
582 (uri (string-append "https://hackage.haskell.org/package/"
583 "test-framework-th-" version "/"
584 "test-framework-th-" version ".tar.gz"))
585 (sha256
586 (base32
587 "12lw7yj02jb9s0i7rb98jjam43j2h0gzmnbj9zi933fx7sg0sy4b"))))
588 (build-system haskell-build-system)
589 (inputs
590 `(("ghc-test-framework" ,ghc-test-framework)
591 ("ghc-language-haskell-extract" ,ghc-language-haskell-extract)
592 ("ghc-haskell-src-exts" ,ghc-haskell-src-exts)
593 ("ghc-regex-posix" ,ghc-regex-posix)))
594 (home-page "https://github.com/finnsson/test-generator")
595 (synopsis "Auto generate the HUnit- and Quickcheck-bulk-code
596 using Template Haskell")
597 (description "This library contains two functions:
598 @code{defaultMainGenerator} and @code{testGroupGenerator}.
599
600 @code{defaultMainGenerator} will extract all functions beginning with
601 @code{case_}, @code{prop_}, or @code{test_} in the module and put them in a
602 @code{testGroup}.
603
604 @code{testGroupGenerator} is like @code{defaultMainGenerator} but without
605 @code{defaultMain}. It is useful if you need a function for the testgroup
606 \(e.g. if you want to be able to call the testgroup from another module).")
607 (license license:bsd-3)))
608
609 (define-public ghc-hunit
610 (package
611 (name "ghc-hunit")
612 (version "1.6.0.0")
613 (outputs '("out" "doc"))
614 (source
615 (origin
616 (method url-fetch)
617 (uri (string-append "https://hackage.haskell.org/package/HUnit/"
618 "HUnit-" version ".tar.gz"))
619 (sha256
620 (base32
621 "1pnhwqq5v8h48gbp3ibv3skfj25mf4zs5svxcavq93p9cswycj3l"))))
622 (build-system haskell-build-system)
623 (inputs
624 ;; We cannot use ghc-call-stack there, because it depends on
625 ;; ghc-nanospec, which depends on ghc-hunit.
626 `(("ghc-call-stack" ,ghc-call-stack-boot)))
627 (home-page "http://hunit.sourceforge.net/")
628 (synopsis "Unit testing framework for Haskell")
629 (description
630 "HUnit is a unit testing framework for Haskell, inspired by the
631 JUnit tool for Java.")
632 (license license:bsd-3)))
633
634 (define-public hspec-discover
635 (package
636 (name "hspec-discover")
637 (version "2.5.5")
638 (source
639 (origin
640 (method url-fetch)
641 (uri (string-append "https://hackage.haskell.org/package/"
642 "hspec-discover/hspec-discover-"
643 version ".tar.gz"))
644 (sha256
645 (base32
646 "04aidzi91ccr9bygmfkjzshz34z9vh8wvqj4zinx2clxq6r7gqfz"))))
647 (build-system haskell-build-system)
648 (native-inputs
649 `(("ghc-quickcheck" ,ghc-quickcheck)
650 ("ghc-hspec-meta" ,ghc-hspec-meta)))
651 (home-page "https://hspec.github.io/")
652 (synopsis "Automatically discover and run Hspec tests")
653 (description "hspec-discover is a tool which automatically discovers and
654 runs Hspec tests.")
655 (license license:expat)))
656
657 (define-public ghc-hspec-core
658 (package
659 (name "ghc-hspec-core")
660 (version "2.5.5")
661 (source
662 (origin
663 (method url-fetch)
664 (uri (string-append "https://hackage.haskell.org/package/hspec-core/"
665 "hspec-core-" version ".tar.gz"))
666 (sha256
667 (base32
668 "1vfrqlpn32s9wiykmkxbnrnd5p56yznw20pf8fwzw78ar4wpz55x"))))
669 (build-system haskell-build-system)
670 (arguments `(#:tests? #f)) ; FIXME: testing libraries are missing.
671 (inputs
672 `(("ghc-setenv" ,ghc-setenv)
673 ("ghc-ansi-terminal" ,ghc-ansi-terminal)
674 ("ghc-async" ,ghc-async)
675 ("ghc-clock" ,ghc-clock)
676 ("ghc-quickcheck-io" ,ghc-quickcheck-io)
677 ("ghc-hunit" ,ghc-hunit)
678 ("ghc-quickcheck" ,ghc-quickcheck)
679 ("ghc-hspec-expectations" ,ghc-hspec-expectations)
680 ("ghc-silently" ,ghc-silently)))
681 (home-page "https://hspec.github.io/")
682 (synopsis "Testing framework for Haskell")
683 (description "This library exposes internal types and functions that can
684 be used to extend Hspec's functionality.")
685 (license license:expat)))
686
687 (define-public ghc-hspec-meta
688 (package
689 (name "ghc-hspec-meta")
690 (version "2.4.6")
691 (source
692 (origin
693 (method url-fetch)
694 (uri (string-append "https://hackage.haskell.org/package/hspec-meta/"
695 "hspec-meta-" version ".tar.gz"))
696 (sha256
697 (base32
698 "0qmvk01n79j6skn79r6zalg2pd0x0nqqn9qn8mhg0pgyzcdnfc9b"))))
699 (build-system haskell-build-system)
700 (inputs
701 `(("ghc-quickcheck" ,ghc-quickcheck)
702 ("ghc-hunit" ,ghc-hunit)
703 ("ghc-ansi-terminal" ,ghc-ansi-terminal)
704 ("ghc-async" ,ghc-async)
705 ("ghc-hspec-expectations" ,ghc-hspec-expectations)
706 ("ghc-setenv" ,ghc-setenv)
707 ("ghc-random" ,ghc-random)
708 ("ghc-quickcheck-io" ,ghc-quickcheck-io)))
709 (home-page "https://hspec.github.io/")
710 (synopsis "Version of Hspec to test Hspec itself")
711 (description "This library provides a stable version of Hspec which is
712 used to test the in-development version of Hspec.")
713 (license license:expat)))
714
715 (define-public ghc-hspec
716 (package
717 (name "ghc-hspec")
718 (version "2.5.5")
719 (source
720 (origin
721 (method url-fetch)
722 (uri (string-append "https://hackage.haskell.org/package/hspec/"
723 "hspec-" version ".tar.gz"))
724 (sha256
725 (base32
726 "1yv4k5b5kkig2q3waj28587sq28wms7wfav5a3lq4dra6jybimfm"))))
727 (build-system haskell-build-system)
728 (inputs
729 `(("ghc-hspec-core" ,ghc-hspec-core)
730 ("hspec-discover" ,hspec-discover)
731 ("ghc-hspec-expectations" ,ghc-hspec-expectations)
732 ("ghc-quickcheck" ,ghc-quickcheck)
733 ("ghc-hunit" ,ghc-hunit)
734 ("ghc-stringbuilder" ,ghc-stringbuilder)
735 ("ghc-hspec-meta" ,ghc-hspec-meta)))
736 (home-page "https://hspec.github.io/")
737 (synopsis "Testing Framework for Haskell")
738 (description "This library provides the Hspec testing framework for
739 Haskell, inspired by the Ruby library RSpec.")
740 (license license:expat)))
741
742 (define-public ghc-hspec-contrib
743 (package
744 (name "ghc-hspec-contrib")
745 (version "0.5.0")
746 (source (origin
747 (method url-fetch)
748 (uri (string-append "https://hackage.haskell.org/package/"
749 "hspec-contrib/hspec-contrib-"
750 version ".tar.gz"))
751 (sha256
752 (base32
753 "13579xdqwbsy8k0vxdcvgy932d4p76mij1rzkzbpqbspfn7399yv"))))
754 (build-system haskell-build-system)
755 (inputs
756 `(("ghc-hspec-core" ,ghc-hspec-core)
757 ("ghc-hunit" ,ghc-hunit)
758 ("ghc-hspec" ,ghc-hspec)
759 ("ghc-quickcheck" ,ghc-quickcheck)))
760 (native-inputs
761 `(("hspec-discover" ,hspec-discover)))
762 (home-page "https://hspec.github.io/")
763 (synopsis "Contributed functionality for Hspec")
764 (description
765 "This package provides contributed Hspec extensions.")
766 (license license:expat)))
767
768 (define-public ghc-hspec-expectations
769 (package
770 (name "ghc-hspec-expectations")
771 (version "0.8.2")
772 (source
773 (origin
774 (method url-fetch)
775 (uri (string-append "https://hackage.haskell.org/package/"
776 "hspec-expectations/hspec-expectations-"
777 version ".tar.gz"))
778 (sha256
779 (base32
780 "1vxl9zazbaapijr6zmcj72j9wf7ka1pirrjbwddwwddg3zm0g5l1"))))
781 (build-system haskell-build-system)
782 ;; Tests depend on ghc-nanospec.
783 (arguments '(#:tests? #f))
784 (inputs `(("ghc-hunit" ,ghc-hunit)))
785 (home-page "https://github.com/sol/hspec-expectations")
786 (synopsis "Catchy combinators for HUnit")
787 (description "This library provides catchy combinators for HUnit, see
788 @uref{https://github.com/sol/hspec-expectations#readme, the README}.")
789 (license license:expat)))
790
791 (define-public ghc-nanospec
792 (package
793 (name "ghc-nanospec")
794 (version "0.2.2")
795 (source
796 (origin
797 (method url-fetch)
798 (uri (string-append "https://hackage.haskell.org/package/"
799 "nanospec/nanospec-"
800 version ".tar.gz"))
801 (sha256
802 (base32
803 "1rcmhl9bhyfvanalnf1r86wkx6rq6wdvagnw1h011jcnnb1cq56g"))))
804 (build-system haskell-build-system)
805 (inputs
806 `(("ghc-hspec" ,ghc-hspec)
807 ("ghc-silently" ,ghc-silently)))
808 (home-page "https://github.com/hspec/nanospec#readme")
809 (synopsis "Lightweight implementation of a subset of Hspec's API")
810 (description
811 "Nanospec is a lightweight implementation of a subset of Hspec's API with
812 minimal dependencies.")
813 (license license:expat)))
814
815 (define-public ghc-crypto-cipher-tests
816 (package
817 (name "ghc-crypto-cipher-tests")
818 (version "0.0.11")
819 (source
820 (origin
821 (method url-fetch)
822 (uri (string-append "https://hackage.haskell.org/package/"
823 "crypto-cipher-tests-" version "/"
824 "crypto-cipher-tests-" version ".tar.gz"))
825 (sha256
826 (base32
827 "19wqignlq90qwpam01hnmmrxaxh5lkax9l1l6rlbi4a07nvp1dnz"))))
828 (build-system haskell-build-system)
829 (inputs `(("ghc-quickcheck" ,ghc-quickcheck)
830 ("ghc-mtl" ,ghc-mtl)
831 ("ghc-hunit" ,ghc-hunit)
832 ("ghc-test-framework" ,ghc-test-framework)
833 ("ghc-test-framework-quickcheck2" ,ghc-test-framework-quickcheck2)
834 ("ghc-test-framework-hunit" ,ghc-test-framework-hunit)
835 ("ghc-byteable" ,ghc-byteable)
836 ("ghc-securemem" ,ghc-securemem)
837 ("ghc-crypto-cipher-types" ,ghc-crypto-cipher-types)))
838 (home-page "https://github.com/vincenthz/hs-crypto-cipher")
839 (synopsis "Generic cryptography cipher tests for Haskell")
840 (description " This Haskell package contains generic tests for
841 cryptographic ciphers, and is used by the test runners of various Haskell
842 implementations of cryptographic ciphers.")
843 (license license:bsd-3)))