gnu: rust-core-foundation-sys-0.6: Don't hide package.
[jackhill/guix/guix.git] / gnu / packages / check.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2012 Nikita Karetnikov <nikita@karetnikov.org>
3 ;;; Copyright © 2014 David Thompson <davet@gnu.org>
4 ;;; Copyright © 2015 Paul van der Walt <paul@denknerd.org>
5 ;;; Copyright © 2014, 2015 Eric Bavier <bavier@member.fsf.org>
6 ;;; Copyright © 2015 Mark H Weaver <mhw@netris.org>
7 ;;; Copyright © 2015, 2017 Cyril Roelandt <tipecaml@gmail.com>
8 ;;; Copyright © 2015 Federico Beffa <beffa@fbengineering.ch>
9 ;;; Copyright © 2015 Andreas Enge <andreas@enge.fr>
10 ;;; Copyright © 2015, 2016, 2018, 2019 Efraim Flashner <efraim@flashner.co.il>
11 ;;; Copyright © 2016, 2017 Leo Famulari <leo@famulari.name>
12 ;;; Copyright © 2016 Christopher Allan Webber <cwebber@dustycloud.org>
13 ;;; Copyright © 2016, 2017 Danny Milosavljevic <dannym+a@scratchpost.org>
14 ;;; Copyright © 2016 Roel Janssen <roel@gnu.org>
15 ;;; Copyright © 2016 Sou Bunnbu <iyzsong@gmail.com>
16 ;;; Copyright © 2016 Troy Sankey <sankeytms@gmail.com>
17 ;;; Copyright © 2016 Lukas Gradl <lgradl@openmailbox.org>
18 ;;; Copyright © 2016 Hartmut Goebel <h.goebel@crazy-compilers.com>
19 ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
20 ;;; Copyright © 2017 Julien Lepiller <julien@lepiller.eu>
21 ;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
22 ;;; Copyright © 2017, 2018 Arun Isaac <arunisaac@systemreboot.net>
23 ;;; Copyright © 2017 Frederick M. Muriithi <fredmanglis@gmail.com>
24 ;;; Copyright © 2017, 2019 Mathieu Othacehe <m.othacehe@gmail.com>
25 ;;; Copyright © 2017, 2019 Kei Kebreau <kkebreau@posteo.net>
26 ;;; Copyright © 2017 ng0 <ng0@n0.is>
27 ;;; Copyright © 2015, 2017, 2018 Ricardo Wurmus <rekado@elephly.net>
28 ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Marius Bakke <mbakke@fastmail.com>
29 ;;; Copyright © 2017, 2018 Ludovic Courtès <ludo@gnu.org>
30 ;;; Copyright © 2018 Fis Trivial <ybbs.daans@hotmail.com>
31 ;;; Copyright © 2019 Pierre Langlois <pierre.langlois@gmx.com>
32 ;;; Copyright © 2019 Chris Marusich <cmmarusich@gmail.com>
33 ;;;
34 ;;; This file is part of GNU Guix.
35 ;;;
36 ;;; GNU Guix is free software; you can redistribute it and/or modify it
37 ;;; under the terms of the GNU General Public License as published by
38 ;;; the Free Software Foundation; either version 3 of the License, or (at
39 ;;; your option) any later version.
40 ;;;
41 ;;; GNU Guix is distributed in the hope that it will be useful, but
42 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
43 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
44 ;;; GNU General Public License for more details.
45 ;;;
46 ;;; You should have received a copy of the GNU General Public License
47 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
48
49 (define-module (gnu packages check)
50 #:use-module (gnu packages)
51 #:use-module (gnu packages autotools)
52 #:use-module (gnu packages base)
53 #:use-module (gnu packages bash)
54 #:use-module (gnu packages compression)
55 #:use-module (gnu packages linux)
56 #:use-module (gnu packages llvm)
57 #:use-module (gnu packages glib)
58 #:use-module (gnu packages gnome)
59 #:use-module (gnu packages golang)
60 #:use-module (gnu packages gtk)
61 #:use-module (gnu packages perl)
62 #:use-module (gnu packages pkg-config)
63 #:use-module (gnu packages python)
64 #:use-module (gnu packages python-web)
65 #:use-module (gnu packages python-xyz)
66 #:use-module (gnu packages time)
67 #:use-module (guix utils)
68 #:use-module ((guix licenses) #:prefix license:)
69 #:use-module (guix packages)
70 #:use-module (guix download)
71 #:use-module (guix git-download)
72 #:use-module (guix build-system cmake)
73 #:use-module (guix build-system gnu)
74 #:use-module (guix build-system go)
75 #:use-module (guix build-system python)
76 #:use-module (guix build-system trivial))
77
78 (define-public check
79 (package
80 (name "check")
81 (version "0.13.0")
82 (source
83 (origin
84 (method url-fetch)
85 (uri (string-append "https://github.com/libcheck/check/releases/download/"
86 version "/check-" version ".tar.gz"))
87 (sha256
88 (base32
89 "02crar51gniijrrl9p8f9maibnwc33n76kw5cqr7xk3s8hqnncy4"))))
90 (build-system gnu-build-system)
91 (home-page "https://libcheck.github.io/check/")
92 (synopsis "Unit test framework for C")
93 (description
94 "Check is a unit testing framework for C. It features a simple
95 interface for defining unit tests, putting little in the way of the
96 developer. Tests are run in a separate address space, so Check can
97 catch both assertion failures and code errors that cause segmentation
98 faults or other signals. The output from unit tests can be used within
99 source code editors and IDEs.")
100 (license license:lgpl2.1+)))
101
102 ;; Some packages require this older version. Removed once no longer needed.
103 (define-public check-0.12
104 (package/inherit
105 check
106 (version "0.12.0")
107 (source (origin
108 (method url-fetch)
109 (uri (string-append "https://github.com/libcheck/check/releases"
110 "/download/" version "/check-" version ".tar.gz"))
111 (sha256
112 (base32
113 "0d22h8xshmbpl9hba9ch3xj8vb9ybm5akpsbbh7yj07fic4h2hj6"))))))
114
115 (define-public cunit
116 (package
117 (name "cunit")
118 (version "2.1-3")
119 (source
120 (origin
121 (method url-fetch)
122 (uri (string-append "mirror://sourceforge/cunit/CUnit/"
123 version "/CUnit-" version ".tar.bz2"))
124 (sha256
125 (base32
126 "057j82da9vv4li4z5ri3227ybd18nzyq81f6gsvhifs5z0vr3cpm"))))
127 (build-system gnu-build-system)
128 (arguments '(#:phases
129 (modify-phases %standard-phases
130 ;; XXX: The "bootstrap" phase detects the "bootstrap"
131 ;; script, but fails to execute it, so we bootstrap
132 ;; manually.
133 (replace 'bootstrap
134 (lambda _ (invoke "autoreconf" "-vfi"))))))
135 (native-inputs
136 `(("automake" ,automake)
137 ("autoconf" ,autoconf)
138 ("libtool" ,libtool)))
139 (home-page "http://cunit.sourceforge.net/")
140 (synopsis "Automated testing framework for C")
141 (description
142 "CUnit is a lightweight system for writing, administering, and running
143 unit tests in C. It provides C programmers with basic testing functionality
144 with a flexible variety of user interfaces.")
145 (license license:gpl2+)))
146
147 (define-public cppunit
148 (package
149 (name "cppunit")
150 (version "1.14.0")
151 (source (origin
152 (method url-fetch)
153 (uri (string-append "http://dev-www.libreoffice.org/src/"
154 name "-" version ".tar.gz"))
155 (sha256
156 (base32
157 "1027cyfx5gsjkdkaf6c2wnjh68882grw8n672018cj3vs9lrhmix"))))
158 ;; Explicitly link with libdl. This is expected to be done by packages
159 ;; relying on cppunit for their tests. However, not all of them do.
160 ;; If we added the linker flag to such packages, we would pollute all
161 ;; binaries, not only those used for testing.
162 (arguments
163 `(#:make-flags '("LDFLAGS=-ldl")))
164 (build-system gnu-build-system)
165 (home-page "https://wiki.freedesktop.org/www/Software/cppunit/")
166 (synopsis "Unit testing framework for C++")
167 (description "CppUnit is the C++ port of the famous JUnit framework for
168 unit testing. Test output is in XML for automatic testing and GUI based for
169 supervised tests.")
170 (license license:lgpl2.1))) ; no copyright notices. LGPL2.1 is in the tarball
171
172 ;; When dependent packages upgraded to use newer version of catch, this one should
173 ;; be removed.
174 (define-public catch-framework
175 (package
176 (name "catch")
177 (version "1.3.5") ;Sub-minor is the build number
178 (source (origin
179 (method git-fetch)
180 (uri (git-reference
181 (url "https://github.com/philsquared/Catch")
182 ;; Semi-arbitrary.
183 (commit "ae5ee2cf63d6d67bd1369b512d2a7b60b571c907")))
184 (file-name (string-append name "-" version))
185 (sha256
186 (base32
187 "1yfb3lxv929szqy1nw9xw3d45wzkppziqshkjxvrb1fdmf46x564"))))
188 (build-system trivial-build-system)
189 (arguments
190 `(#:modules ((guix build utils))
191 #:builder (begin
192 (use-modules (guix build utils))
193 (let* ((source (assoc-ref %build-inputs "source"))
194 (output (assoc-ref %outputs "out"))
195 (incdir (string-append output "/include"))
196 (docdir (string-append output "/share/doc/catch-"
197 ,version)))
198 (for-each mkdir-p (list incdir docdir))
199 (install-file (string-append source
200 "/single_include/catch.hpp")
201 incdir)
202 (copy-recursively (string-append source "/docs")
203 docdir)
204 #t))))
205 (home-page "http://catch-lib.net/")
206 (synopsis "Automated test framework for C++ and Objective-C")
207 (description
208 "Catch stands for C++ Automated Test Cases in Headers and is a
209 multi-paradigm automated test framework for C++ and Objective-C.")
210 (license license:boost1.0)))
211
212 (define-public catch-framework2-1
213 (package
214 (name "catch2")
215 (version "1.12.2")
216 (home-page "https://github.com/catchorg/Catch2")
217 (source (origin
218 (method git-fetch)
219 (uri (git-reference
220 (url "https://github.com/catchorg/Catch2")
221 (commit (string-append "v" version))))
222 (file-name (git-file-name name version))
223 (sha256
224 (base32
225 "1gdp5wm8khn02g2miz381llw3191k7309qj8s3jd6sasj01rhf23"))))
226 (build-system cmake-build-system)
227 (synopsis "Automated test framework for C++ and Objective-C")
228 (description "Catch2 stands for C++ Automated Test Cases in Headers and is
229 a multi-paradigm automated test framework for C++ and Objective-C.")
230 (license license:boost1.0)))
231
232 (define-public catch-framework2
233 (package
234 (name "catch2")
235 (version "2.1.2")
236 (home-page "https://github.com/catchorg/Catch2")
237 (source (origin
238 (method git-fetch)
239 (uri (git-reference
240 (url "https://github.com/catchorg/Catch2")
241 (commit (string-append "v" version))))
242 (file-name (git-file-name name version))
243 (sha256
244 (base32
245 "14vcckqmbydjsg40ngi6iv999zimysh2l7fmrqj1d7xl990qz233"))))
246 (build-system cmake-build-system)
247 (inputs
248 `(("python" ,python-wrapper)))
249 (synopsis "Automated test framework for C++ and Objective-C")
250 (description "Catch2 stands for C++ Automated Test Cases in Headers and is
251 a multi-paradigm automated test framework for C++ and Objective-C.")
252 (license license:boost1.0)))
253
254 (define-public cmdtest
255 (package
256 (name "cmdtest")
257 (version "0.32")
258 (source (origin
259 (method url-fetch)
260 (uri (string-append "http://git.liw.fi/cmdtest/snapshot/"
261 name "-" version ".tar.gz"))
262 (sha256
263 (base32
264 "1jmfiyrrqmpvwdb273bkb8hjaf4rwx9njblx29pmr7giyahskwi5"))))
265 (build-system python-build-system)
266 (arguments
267 `(#:python ,python-2
268 #:phases
269 (modify-phases %standard-phases
270 ;; check phase needs to be run before the build phase. If not, the
271 ;; coverage test runner looks for tests for the built source files,
272 ;; and fails.
273 (delete 'check)
274 (add-before 'build 'check
275 (lambda _
276 (substitute* "yarn"
277 (("/bin/sh") (which "sh")))
278 ;; yarn uses python2-ttystatus to print messages.
279 ;; python2-ttystatus requires /dev/tty which is not present in
280 ;; the build environment. Hence assuming-failure test fails.
281 (delete-file "yarn.tests/assuming-failure.script")
282 (delete-file "yarn.tests/assuming-failure.stdout")
283 (invoke "python" "setup.py" "check"))))))
284 (native-inputs
285 `(("python2-coverage-test-runner" ,python2-coverage-test-runner)))
286 (propagated-inputs
287 `(("python2-cliapp" ,python2-cliapp)
288 ("python2-markdown" ,python2-markdown)
289 ("python2-ttystatus" ,python2-ttystatus)))
290 (home-page "https://liw.fi/cmdtest/")
291 (synopsis "Black box Unix program tester")
292 (description
293 "@code{cmdtest} black box tests Unix command line tools. Roughly, it is
294 given a command line and input files, and the expected output, and it verifies
295 that the command line produces the expected output. If not, it reports a
296 problem, and shows the differences.")
297 (license license:gpl3+)))
298
299 (define-public cmocka
300 (package
301 (name "cmocka")
302 (version "1.1.5")
303 (source (origin
304 (method url-fetch)
305 (uri (string-append "https://cmocka.org/files/"
306 (version-major+minor version) "/cmocka-"
307 version ".tar.xz"))
308 (sha256
309 (base32
310 "1dm8pdvkyfa8dsbz9bpq7wwgixjij4sii9bbn5sgvqjm5ljdik7h"))))
311 (build-system cmake-build-system)
312 (arguments
313 `(#:tests? #f)) ; no test target
314 (home-page "https://cmocka.org/")
315 (synopsis "Unit testing framework for C")
316 (description "Cmocka is a unit testing framework for C with support for
317 mock objects. It only requires the standard C library, and works with
318 different compilers. Cmocka supports several different message output formats
319 like Test Anything Protocol, Subunit, xUnit XML or the original cmockery output
320 format.")
321 (license license:asl2.0)))
322
323 (define-public cppcheck
324 (package
325 (name "cppcheck")
326 (version "1.90")
327 (source (origin
328 (method git-fetch)
329 (uri (git-reference
330 (url "https://github.com/danmar/cppcheck")
331 (commit version)))
332 (file-name (git-file-name name version))
333 (sha256
334 (base32 "0h7ir2x0k005fm586dxmaphgv5cyz25k3k4sh02p7zb78gzx398h"))))
335 (build-system cmake-build-system)
336 (arguments
337 '(#:configure-flags '("-DBUILD_TESTS=ON")))
338 (home-page "http://cppcheck.sourceforge.net")
339 (synopsis "Static C/C++ code analyzer")
340 (description "Cppcheck is a static code analyzer for C and C++. Unlike
341 C/C++ compilers and many other analysis tools it does not detect syntax errors
342 in the code. Cppcheck primarily detects the types of bugs that the compilers
343 normally do not detect. The goal is to detect only real errors in the code
344 (i.e. have zero false positives).")
345 (license license:gpl3+)))
346
347 (define-public cxxtest
348 (package
349 (name "cxxtest")
350 (version "4.4")
351 (source (origin
352 (method url-fetch)
353 (uri (string-append "mirror://sourceforge/cxxtest/cxxtest/"
354 version "/cxxtest-" version ".tar.gz"))
355 (sha256
356 (base32
357 "1n7pbj4z9ivx005hqvivj9ddhq8awynzg6jishfbypf6j7ply58w"))))
358 (build-system python-build-system)
359 (arguments
360 '(#:phases
361 (modify-phases %standard-phases
362 (add-after 'unpack 'chdir-to-source
363 (lambda _
364 (chdir "python")
365 #t))
366 (add-after 'install 'install-headers
367 (lambda* (#:key outputs #:allow-other-keys)
368 (let* ((out (assoc-ref outputs "out"))
369 (include-dir (string-append out "/include/cxxtest")))
370 (for-each (lambda (header-file)
371 (install-file header-file include-dir))
372 (find-files "../cxxtest"))
373 #t)))
374 (add-after 'install 'install-doc
375 (lambda* (#:key outputs #:allow-other-keys)
376 (let* ((out (assoc-ref outputs "out"))
377 (doc-dir (string-append out "/share/doc/cxxtest")))
378 (install-file "../README" doc-dir)
379 (install-file "../doc/guide.txt" doc-dir)
380 (copy-recursively "../sample" (string-append doc-dir "/sample"))
381 #t))))))
382 (propagated-inputs
383 `(("python-ply" ,python-ply)))
384 (home-page "https://cxxtest.com/")
385 (synopsis "Unit testing framework for C++")
386 (description "CxxTest is a unit testing framework for C++ that is similar
387 in spirit to JUnit, CppUnit, and xUnit. CxxTest does not require precompiling
388 a CxxTest testing library, it employs no advanced features of C++ (e.g. RTTI)
389 and it supports a very flexible form of test discovery.")
390 (license license:lgpl3+)))
391
392 (define-public doctest
393 (package
394 (name "doctest")
395 (version "2.3.6")
396 (home-page "https://github.com/onqtam/doctest")
397 (source (origin
398 (method git-fetch)
399 (uri (git-reference (url home-page) (commit version)))
400 (file-name (git-file-name name version))
401 (sha256
402 (base32
403 "070gkwffi73i2p0azga9yxj8km32bp8bw4jvkvz1vzlpavyii5kn"))))
404 (build-system cmake-build-system)
405 (synopsis "C++ test framework")
406 (description
407 "doctest is a single-header testing framework for C++11 and later. It
408 has been designed to be fast, light and unintrusive.")
409 (license license:expat)))
410
411 (define-public go-gopkg.in-check.v1
412 (let ((commit "788fd78401277ebd861206a03c884797c6ec5541")
413 (revision "1"))
414 (package
415 (name "go-gopkg.in-check.v1")
416 (version (git-version "0.0.0" revision commit))
417 (source (origin
418 (method git-fetch)
419 (uri (git-reference
420 (url "https://github.com/go-check/check.git")
421 (commit commit)))
422 (file-name (git-file-name name version))
423 (sha256
424 (base32
425 "0v3bim0j375z81zrpr5qv42knqs0y2qv2vkjiqi5axvb78slki1a"))))
426 (build-system go-build-system)
427 (arguments
428 '(#:import-path "gopkg.in/check.v1"))
429 (propagated-inputs
430 `(("go-github-com-kr-pretty" ,go-github-com-kr-pretty)))
431 (synopsis "Rich testing extension for Go's testing package")
432 (description
433 "@code{check} is a rich testing extension for Go's testing package.")
434 (home-page "https://github.com/go-check/check")
435 (license license:bsd-2))))
436
437 (define-public go-github.com-smartystreets-gunit
438 (package
439 (name "go-github.com-smartystreets-gunit")
440 (version "1.0.0")
441 (source (origin
442 (method git-fetch)
443 (uri (git-reference
444 (url "https://github.com/smartystreets/gunit")
445 (commit version)))
446 (file-name (git-file-name name version))
447 (sha256
448 (base32
449 "00m4zg0kdj49mnpmf9klb44ba71p966xsk6zknrzqgfc8119f35z"))))
450 (build-system go-build-system)
451 (arguments
452 '(;; TODO: This package depends on go-github.com-smartystreets-assertions
453 ;; for running the tests, but go-github.com-smartystreets-assertions
454 ;; depends on this package, so break this loop by not running the tests
455 ;; for this package.
456 #:tests? #f
457 #:import-path "github.com/smartystreets/gunit"))
458 (synopsis "Testing tool for Go, in the style of xUnit")
459 (description
460 "@code{gunit} allows the test author to use a struct as the scope for a
461 group of related test cases, in the style of xUnit fixtures. This makes
462 extraction of setup/teardown behavior (as well as invoking the system under
463 test) much simpler.")
464 (home-page "https://github.com/smartystreets/gunit")
465 (license license:expat)))
466
467 (define-public go-github.com-smartystreets-assertions
468 (package
469 (name "go-github.com-smartystreets-assertions")
470 (version "1.8.1")
471 (source (origin
472 (method git-fetch)
473 (uri (git-reference
474 (url "https://github.com/smartystreets/assertions")
475 (commit version)))
476 (file-name (git-file-name name version))
477 (sha256
478 (base32
479 "1j0adgbykl55rf2945g0n5bmqdsnjcqlx5dcmpfh4chki43hiwg9"))))
480 (build-system go-build-system)
481 (arguments
482 '(#:import-path "github.com/smartystreets/assertions"))
483 (native-inputs
484 `(("go-github.com-smartystreets-gunit" ,go-github.com-smartystreets-gunit)))
485 (synopsis "Assertions for testing with Go")
486 (description
487 "The @code{assertions} package provides convenient assertion functions
488 for writing tests in Go.")
489 (home-page "https://github.com/smartystreets/assertions")
490 (license license:expat)))
491
492 (define-public go-github.com-smartystreets-goconvey
493 (package
494 (name "go-github.com-smartystreets-goconvey")
495 (version "1.6.3")
496 (source (origin
497 (method git-fetch)
498 (uri (git-reference
499 (url "https://github.com/smartystreets/goconvey")
500 (commit version)))
501 (file-name (git-file-name name version))
502 (sha256
503 (base32
504 "1ph18rkl3ns3fgin5i4j54w5a69grrmf3apcsmnpdn1wlrbs3dxh"))))
505 (build-system go-build-system)
506 (arguments
507 '(#:import-path "github.com/smartystreets/goconvey"))
508 (propagated-inputs
509 `(("go-github.com-jtolds-gls" ,go-github.com-jtolds-gls)
510 ("go-github.com-smartystreets-assertions" ,go-github.com-smartystreets-assertions)))
511 (synopsis "Go testing tool with both a web and terminal user interface")
512 (description
513 "GoConvey is a testing tool for Go. It integrates with go test, can show
514 test coverage and has a web user interface that will refresh automatically.")
515 (home-page "https://github.com/smartystreets/goconvey")
516 (license license:expat)))
517
518 (define-public googletest
519 (package
520 (name "googletest")
521 (version "1.10.0")
522 (source
523 (origin
524 (method git-fetch)
525 (uri (git-reference
526 (url "https://github.com/google/googletest.git")
527 (commit (string-append "release-" version))))
528 (file-name (git-file-name name version))
529 (sha256
530 (base32 "1zbmab9295scgg4z2vclgfgjchfjailjnvzc6f5x9jvlsdi3dpwz"))))
531 (build-system cmake-build-system)
532 (arguments
533 `(#:configure-flags '("-DBUILD_SHARED_LIBS=ON")))
534 (native-inputs
535 `(("python" ,python-wrapper)))
536 (home-page "https://github.com/google/googletest/")
537 (synopsis "Test discovery and XUnit test framework")
538 (description "Google Test features an XUnit test framework, automated test
539 discovery, death tests, assertions, parameterized tests and XML test report
540 generation.")
541 (license license:bsd-3)))
542
543 (define-public googletest-1.8
544 (package/inherit
545 googletest
546 (version "1.8.1")
547 (source (origin
548 (method git-fetch)
549 (uri (git-reference
550 (url "https://github.com/google/googletest.git")
551 (commit (string-append "release-" version))))
552 (file-name (git-file-name "googletest" version))
553 (sha256
554 (base32
555 "0270msj6n7mggh4xqqjp54kswbl7mkcc8px1p5dqdpmw5ngh9fzk"))))))
556
557 (define-public cpputest
558 (package
559 (name "cpputest")
560 (version "3.8")
561 (source
562 (origin
563 (method url-fetch)
564 (uri (string-append "https://github.com/cpputest/cpputest/releases/download/v"
565 version "/cpputest-" version ".tar.gz"))
566 (sha256
567 (base32
568 "0mk48xd3klyqi7wf3f4wn4zqxxzmvrhhl32r25jzrixzl72wq7f8"))))
569 (build-system gnu-build-system)
570 (native-inputs
571 `(("googletest" ,googletest)))
572 (home-page "https://cpputest.github.io/")
573 (synopsis "Unit testing and mocking framework for C/C++")
574 (description
575 "CppUTest is a C/C++ based unit xUnit test framework. It is written in
576 C++ but is used in C and C++ projects and frequently used in embedded systems
577 but it works for any C/C++ project.")
578 (license license:bsd-3)))
579
580 (define-public python-parameterized
581 (package
582 (name "python-parameterized")
583 (version "0.6.1")
584 (source
585 (origin
586 (method url-fetch)
587 (uri (pypi-uri "parameterized" version))
588 (sha256
589 (base32
590 "1qj1939shm48d9ql6fm1nrdy4p7sdyj8clz1szh5swwpf1qqxxfa"))))
591 (build-system python-build-system)
592 (arguments '(#:tests? #f)) ; there are no tests
593 (home-page "https://github.com/wolever/parameterized")
594 (synopsis "Parameterized testing with any Python test framework")
595 (description
596 "Parameterized is a Python library that aims to fix parameterized testing
597 for every Python test framework. It supports nose, py.test, and unittest.")
598 (license license:bsd-2)))
599
600 (define-public python2-parameterized
601 (package-with-python2 python-parameterized))
602
603 (define-public python-minimock
604 (package
605 (name "python-minimock")
606 (version "1.2.8")
607 (source
608 (origin
609 (method url-fetch)
610 (uri (pypi-uri "MiniMock" version))
611 (sha256
612 (base32
613 "0k2sxb1ibnyg05iblz7zhbv825f1zk9906rab7883iqgvzmdzpsz"))))
614 (build-system python-build-system)
615 (home-page "https://pypi.org/project/MiniMock")
616 (synopsis "Simple Python library for using mock objects")
617 (description "MiniMock is a simple library for building mock objects with
618 doctest.")
619 (license license:expat)))
620
621 (define-public python2-minimock
622 (package-with-python2 python-minimock))
623
624 (define-public python-mock
625 (package
626 (name "python-mock")
627 (version "2.0.0")
628 (source
629 (origin
630 (method url-fetch)
631 (uri (pypi-uri "mock" version))
632 (sha256
633 (base32
634 "1flbpksir5sqrvq2z0dp8sl4bzbadg21sj4d42w3klpdfvgvcn5i"))))
635 (propagated-inputs
636 `(("python-pbr" ,python-pbr-minimal)
637 ("python-six" ,python-six)))
638 (build-system python-build-system)
639 (native-inputs
640 `(("python-unittest2" ,python-unittest2)))
641 (arguments
642 `(#:phases
643 (modify-phases %standard-phases
644 (replace 'check
645 (lambda _
646 (zero? (system* "unit2")))))))
647 (home-page "https://github.com/testing-cabal/mock")
648 (synopsis "Python mocking and patching library for testing")
649 (description
650 "Mock is a library for testing in Python. It allows you to replace parts
651 of your system under test with mock objects and make assertions about how they
652 have been used.")
653 (properties `((python2-variant . ,(delay python2-mock))))
654 (license license:expat)))
655
656 (define-public python2-mock
657 (let ((base (package-with-python2
658 (strip-python2-variant python-mock))))
659 (package (inherit base)
660 (propagated-inputs
661 `(("python2-functools32" ,python2-functools32)
662 ("python2-funcsigs" ,python2-funcsigs)
663 ,@(package-propagated-inputs base))))))
664
665 (define-public python-nose
666 (package
667 (name "python-nose")
668 (version "1.3.7")
669 (source
670 (origin
671 (method url-fetch)
672 (uri (pypi-uri "nose" version))
673 (sha256
674 (base32
675 "164a43k7k2wsqqk1s6vavcdamvss4mz0vd6pwzv2h9n8rgwzxgzi"))))
676 (build-system python-build-system)
677 (arguments
678 '(#:tests? #f)) ; FIXME: test suite fails
679 (home-page "http://readthedocs.org/docs/nose/")
680 (synopsis "Python testing library")
681 (description
682 "Nose extends the unittest library to make testing easier.")
683 (license license:lgpl2.0+)))
684
685 (define-public python2-nose
686 (package-with-python2 python-nose))
687
688 (define-public python-nose2
689 (package
690 (name "python-nose2")
691 (version "0.6.5")
692 (source
693 (origin
694 (method url-fetch)
695 (uri (pypi-uri "nose2" version))
696 (sha256
697 (base32
698 "1x4zjq1zlyrh8b9ba0cmafd3w94pxhid408kibyjd3s6h1lap6s7"))))
699 (build-system python-build-system)
700 (arguments `(#:tests? #f)) ; 'module' object has no attribute 'collector'
701 (propagated-inputs
702 `(("python-cov-core" ,python-cov-core)
703 ("python-pytest-cov" ,python-pytest-cov)
704 ("python-six" ,python-six)))
705 (home-page "https://github.com/nose-devs/nose2")
706 (synopsis "Next generation of nicer testing for Python")
707 (description
708 "Nose2 is the next generation of nicer testing for Python, based on the
709 plugins branch of unittest2. Nose2 aims to improve on nose by providing a
710 better plugin api, being easier for users to configure, and simplifying internal
711 interfaces and processes.")
712 (license license:bsd-2)))
713
714 (define-public python2-nose2
715 (package-with-python2 python-nose2))
716
717 (define-public python-unittest2
718 (package
719 (name "python-unittest2")
720 (version "1.1.0")
721 (source
722 (origin
723 (method url-fetch)
724 (uri (pypi-uri "unittest2" version))
725 (patches
726 (search-patches "python-unittest2-python3-compat.patch"
727 "python-unittest2-remove-argparse.patch"))
728 (sha256
729 (base32
730 "0y855kmx7a8rnf81d3lh5lyxai1908xjp0laf4glwa4c8472m212"))))
731 (build-system python-build-system)
732 (arguments
733 '(#:phases
734 (modify-phases %standard-phases
735 (replace 'check
736 (lambda _
737 (zero? (system* "python" "-m" "unittest2" "discover" "--verbose")))))))
738 (propagated-inputs
739 `(("python-six" ,python-six)
740 ("python-traceback2" ,python-traceback2)))
741 (home-page "http://pypi.python.org/pypi/unittest2")
742 (synopsis "Python unit testing library")
743 (description
744 "Unittest2 is a replacement for the unittest module in the Python
745 standard library.")
746 (license license:psfl)))
747
748 (define-public python2-unittest2
749 (package-with-python2 python-unittest2))
750
751 (define-public python-pytest
752 (package
753 (name "python-pytest")
754 (version "4.4.2")
755 (source
756 (origin
757 (method url-fetch)
758 (uri (pypi-uri "pytest" version))
759 (sha256
760 (base32
761 "18w38kjnffdcrlbw6ny6dksgxai6x9bxpjs2m6klqmb8hfzjkcb2"))))
762 (build-system python-build-system)
763 (arguments
764 `(#:phases
765 (modify-phases %standard-phases
766 (replace 'check
767 (lambda _
768 (invoke "pytest" "-vv" "-k"
769 (string-append
770 ;; These tests involve the /usr directory, and fails.
771 "not test_remove_dir_prefix"
772 " and not test_argcomplete"
773 ;; This test tries to override PYTHONPATH, and
774 ;; subsequently fails to locate the test libraries.
775 " and not test_collection")))))))
776 (propagated-inputs
777 `(("python-atomicwrites" ,python-atomicwrites)
778 ("python-attrs" ,python-attrs-bootstrap)
779 ("python-more-itertools" ,python-more-itertools)
780 ("python-pluggy" ,python-pluggy)
781 ("python-py" ,python-py)
782 ("python-six" ,python-six-bootstrap)))
783 (native-inputs
784 `(;; Tests need the "regular" bash since 'bash-final' lacks `compgen`.
785 ("bash" ,bash)
786 ("python-hypothesis" ,python-hypothesis)
787 ("python-nose" ,python-nose)
788 ("python-mock" ,python-mock)
789 ("python-pytest" ,python-pytest-bootstrap)
790 ("python-setuptools-scm" ,python-setuptools-scm)))
791 (home-page "https://docs.pytest.org/en/latest/")
792 (synopsis "Python testing library")
793 (description
794 "Pytest is a testing tool that provides auto-discovery of test modules
795 and functions, detailed info on failing assert statements, modular fixtures,
796 and many external plugins.")
797 (license license:expat)
798 (properties `((python2-variant . ,(delay python2-pytest))))))
799
800 (define-public python2-pytest
801 (let ((pytest (package-with-python2
802 (strip-python2-variant python-pytest))))
803 (package
804 (inherit pytest)
805 (propagated-inputs
806 `(("python2-funcsigs" ,python2-funcsigs)
807 ("python2-pathlib2" ,python2-pathlib2)
808 ,@(package-propagated-inputs pytest))))))
809
810 (define-public python-pytest-bootstrap
811 (package
812 (inherit (strip-python2-variant python-pytest))
813 (name "python-pytest-bootstrap")
814 (native-inputs `(("python-setuptools-scm" ,python-setuptools-scm)))
815 (arguments `(#:tests? #f))
816 (properties `((python2-variant . ,(delay python2-pytest-bootstrap))))))
817
818 (define-public python2-pytest-bootstrap
819 (let ((pytest (package-with-python2
820 (strip-python2-variant python-pytest-bootstrap))))
821 (package (inherit pytest)
822 (propagated-inputs
823 `(("python2-funcsigs" ,python2-funcsigs-bootstrap)
824 ("python2-pathlib2" ,python2-pathlib2-bootstrap)
825 ,@(package-propagated-inputs pytest))))))
826
827 (define-public python-pytest-cov
828 (package
829 (name "python-pytest-cov")
830 (version "2.6.1")
831 (source
832 (origin
833 (method url-fetch)
834 (uri (pypi-uri "pytest-cov" version))
835 (sha256
836 (base32 "0cyxbbghx2l4p60w10k00j1j74q1ngfiffr0pxn73ababjr69dha"))))
837 (build-system python-build-system)
838 (arguments
839 `(#:phases
840 (modify-phases %standard-phases
841 (replace 'check
842 (lambda _
843 ;; Options taken from tox.ini.
844 ;; TODO: make "--restructuredtext" tests pass. They currently fail
845 ;; with "Duplicate implicit target name".
846 (invoke "python" "./setup.py" "check"
847 "--strict" "--metadata"))))))
848 (propagated-inputs
849 `(("python-coverage" ,python-coverage)
850 ("python-pytest" ,python-pytest)))
851 (home-page "https://github.com/pytest-dev/pytest-cov")
852 (synopsis "Pytest plugin for measuring coverage")
853 (description
854 "Pytest-cov produces coverage reports. It supports centralised testing and
855 distributed testing in both @code{load} and @code{each} modes. It also
856 supports coverage of subprocesses.")
857 (license license:expat)))
858
859 (define-public python2-pytest-cov
860 (package-with-python2 python-pytest-cov))
861
862 (define-public python-pytest-runner
863 (package
864 (name "python-pytest-runner")
865 (version "4.4")
866 (source
867 (origin
868 (method url-fetch)
869 (uri (pypi-uri "pytest-runner" version))
870 (sha256
871 (base32
872 "1x0d9n40lsiphblbs61rdc0d5r31f6vh0vcahqdv0mffakbnrb80"))))
873 (build-system python-build-system)
874 (native-inputs
875 `(("python-pytest" ,python-pytest-bootstrap)
876 ("python-setuptools-scm" ,python-setuptools-scm)))
877 (home-page "https://github.com/pytest-dev/pytest-runner")
878 (synopsis "Invoke py.test as a distutils command")
879 (description
880 "This package provides a @command{pytest-runner} command that
881 @file{setup.py} files can use to run tests.")
882 (license license:expat)))
883
884 (define-public python2-pytest-runner
885 (package-with-python2 python-pytest-runner))
886
887 ;; python-bleach 3.1.0 requires this ancient version of pytest-runner.
888 ;; Remove once no longer needed.
889 (define-public python-pytest-runner-2
890 (package/inherit
891 python-pytest-runner
892 (version "2.12.2")
893 (source (origin
894 (method url-fetch)
895 (uri (pypi-uri "pytest-runner" version))
896 (sha256
897 (base32
898 "11ivjj9hfphkv4yfb2g74av4yy86y8gcbf7gbif0p1hcdfnxg3w6"))))))
899
900 (define-public python2-pytest-runner-2
901 (package-with-python2 python-pytest-runner-2))
902
903 (define-public python-pytest-mock
904 (package
905 (name "python-pytest-mock")
906 (version "1.10.1")
907 (source
908 (origin
909 (method url-fetch)
910 (uri (pypi-uri "pytest-mock" version))
911 (sha256
912 (base32
913 "1i5mg3ff1qk0wqfcxfz60hwy3q5dskdp36i10ckigkzffg8hc3ad"))))
914 (build-system python-build-system)
915 (native-inputs
916 `(("python-setuptools-scm" ,python-setuptools-scm)))
917 (propagated-inputs
918 `(("python-pytest" ,python-pytest)))
919 (home-page "https://github.com/pytest-dev/pytest-mock/")
920 (synopsis "Thin-wrapper around the mock package for easier use with py.test")
921 (description
922 "This plugin installs a @code{mocker} fixture which is a thin-wrapper
923 around the patching API provided by the @code{mock} package, but with the
924 benefit of not having to worry about undoing patches at the end of a test.
925 The mocker fixture has the same API as @code{mock.patch}, supporting the
926 same arguments.")
927 (properties `((python2-variant . ,(delay python2-pytest-mock))))
928 (license license:expat)))
929
930 (define-public python2-pytest-mock
931 (let ((base (package-with-python2
932 (strip-python2-variant python-pytest-mock))))
933 (package (inherit base)
934 (propagated-inputs
935 `(("python2-mock" ,python2-mock)
936 ,@(package-propagated-inputs base))))))
937
938 (define-public python-pytest-xdist
939 (package
940 (name "python-pytest-xdist")
941 (version "1.25.0")
942 (source
943 (origin
944 (method url-fetch)
945 (uri (pypi-uri "pytest-xdist" version))
946 (sha256
947 (base32
948 "1d812apvcmshh2l8f38spqwb3bpp0x43yy7lyfpxxzc99h4r7y4n"))
949 (modules '((guix build utils)))
950 (snippet
951 '(begin
952 ;; Remove pre-compiled .pyc files from source.
953 (for-each delete-file-recursively
954 (find-files "." "__pycache__" #:directories? #t))
955 (for-each delete-file (find-files "." "\\.pyc$"))
956 #t))))
957 (build-system python-build-system)
958 (arguments
959 '(#:tests? #f)) ;FIXME: Some tests are failing.
960 ;; #:phases
961 ;; (modify-phases %standard-phases
962 ;; (delete 'check)
963 ;; (add-after 'install 'check
964 ;; (lambda* (#:key inputs outputs #:allow-other-keys)
965 ;; (add-installed-pythonpath inputs outputs)
966 ;; (zero? (system* "py.test" "-v")))))
967 (native-inputs
968 `(("python-setuptools-scm" ,python-setuptools-scm)))
969 (propagated-inputs
970 `(("python-execnet" ,python-execnet)
971 ("python-pytest" ,python-pytest)
972 ("python-py" ,python-py)))
973 (home-page
974 "https://github.com/pytest-dev/pytest-xdist")
975 (synopsis
976 "Plugin for py.test with distributed testing and loop-on-failing modes")
977 (description
978 "The pytest-xdist plugin extends py.test with some unique test execution
979 modes: parallelization, running tests in boxed subprocesses, the ability
980 to run tests repeatedly when failed, and the ability to run tests on multiple
981 Python interpreters or platforms. It uses rsync to copy the existing
982 program code to a remote location, executes there, and then syncs the
983 result back.")
984 (license license:expat)))
985
986 (define-public python2-pytest-xdist
987 (package-with-python2 python-pytest-xdist))
988
989 (define-public python-pytest-timeout
990 (package
991 (name "python-pytest-timeout")
992 (version "1.3.3")
993 (source
994 (origin
995 (method url-fetch)
996 (uri (pypi-uri "pytest-timeout" version))
997 (sha256
998 (base32
999 "1cczcjhw4xx5sjkhxlhc5c1bkr7x6fcyx12wrnvwfckshdvblc2a"))))
1000 (build-system python-build-system)
1001 (propagated-inputs
1002 `(("python-pytest" ,python-pytest)))
1003 (home-page "http://bitbucket.org/pytest-dev/pytest-timeout/")
1004 (synopsis "Plugin for py.test to abort hanging tests")
1005 (description
1006 "This package provides a py.test plugin that aborts hanging tests after a
1007 timeout has been exceeded.")
1008 (license license:expat)))
1009
1010 (define-public python-scripttest
1011 (package
1012 (name "python-scripttest")
1013 (version "1.3")
1014 (source
1015 (origin
1016 (method url-fetch)
1017 (uri (pypi-uri "scripttest" version))
1018 (sha256
1019 (base32
1020 "0f4w84k8ck82syys7yg9maz93mqzc8p5ymis941x034v44jzq74m"))))
1021 (build-system python-build-system)
1022 (native-inputs
1023 `(("python-pytest" ,python-pytest)))
1024 (home-page "http://pythonpaste.org/scripttest/")
1025 (synopsis "Python library to test command-line scripts")
1026 (description "Scripttest is a Python helper library for testing
1027 interactive command-line applications. With it you can run a script in a
1028 subprocess and see the output as well as any file modifications.")
1029 (license license:expat)))
1030
1031 (define-public python2-scripttest
1032 (package-with-python2 python-scripttest))
1033
1034 (define-public python-testtools-bootstrap
1035 (package
1036 (name "python-testtools-bootstrap")
1037 (version "2.3.0")
1038 (source
1039 (origin
1040 (method url-fetch)
1041 (uri (pypi-uri "testtools" version))
1042 (sha256
1043 (base32
1044 "0n8519lk8aaa91vymz842831181wf7fss98hyllhygi3z1nfq9sq"))
1045 (patches (search-patches "python-testtools.patch"))))
1046 (build-system python-build-system)
1047 (arguments '(#:tests? #f))
1048 (propagated-inputs
1049 `(("python-extras" ,python-extras)
1050 ("python-fixtures" ,python-fixtures-bootstrap)
1051 ("python-mimeparse" ,python-mimeparse)
1052 ("python-pbr" ,python-pbr-minimal)
1053 ("python-six" ,python-six)
1054 ("python-traceback2" ,python-traceback2)
1055 ("python-unittest2" ,python-unittest2)))
1056 (home-page "https://github.com/testing-cabal/testtools")
1057 (synopsis
1058 "Extensions to the Python standard library unit testing framework")
1059 (description
1060 "This package is only for bootstrapping. Do not use this.")
1061 (license license:psfl)))
1062
1063 (define-public python2-testtools-bootstrap
1064 (package-with-python2 python-testtools-bootstrap))
1065
1066 (define-public python-testtools
1067 (package
1068 (inherit python-testtools-bootstrap)
1069 (name "python-testtools")
1070 (arguments
1071 `(#:phases (modify-phases %standard-phases
1072 (replace 'check
1073 (lambda _
1074 (invoke "python" "-m" "testtools.run"
1075 "testtools.tests.test_suite"))))))
1076 (propagated-inputs
1077 `(("python-extras" ,python-extras)
1078 ("python-fixtures" ,python-fixtures)
1079 ("python-mimeparse" ,python-mimeparse)
1080 ("python-pbr" ,python-pbr)
1081 ("python-six" ,python-six)
1082 ("python-traceback2" ,python-traceback2)
1083 ("python-unittest2" ,python-unittest2)))
1084 (native-inputs
1085 `(("python-testscenarios" ,python-testscenarios-bootstrap)))
1086 (description
1087 "Testtools extends the Python standard library unit testing framework to
1088 provide matchers, more debugging information, and cross-Python
1089 compatibility.")))
1090
1091 (define-public python2-testtools
1092 (package-with-python2 python-testtools))
1093
1094 (define-public python-testscenarios-bootstrap
1095 (package
1096 (name "python-testscenarios-bootstrap")
1097 (version "0.5.0")
1098 (source
1099 (origin
1100 (method url-fetch)
1101 (uri (pypi-uri "testscenarios" version))
1102 (sha256
1103 (base32
1104 "1dm2aydqpv76vnsk1pw7k8n42hq58cfi4n1ixy7nyzpaj1mwnmy2"))))
1105 (build-system python-build-system)
1106 (arguments
1107 `(#:phases (modify-phases %standard-phases
1108 (replace 'check
1109 (lambda _
1110 (invoke "python" "-m" "testtools.run"
1111 "testscenarios.test_suite"))))))
1112 (propagated-inputs
1113 `(("python-pbr" ,python-pbr-minimal)
1114 ("python-testtools" ,python-testtools-bootstrap)))
1115 (home-page "https://launchpad.net/testscenarios")
1116 (synopsis "Pyunit extension for dependency injection")
1117 (description
1118 "This package is only for bootstrapping. Don't use this.")
1119 (license (list license:bsd-3 license:asl2.0)))) ; at the user's option
1120
1121 (define-public python2-testscenarios-bootstrap
1122 (package-with-python2 python-testscenarios-bootstrap))
1123
1124 (define-public python-testscenarios
1125 (package
1126 (inherit python-testscenarios-bootstrap)
1127 (name "python-testscenarios")
1128 (propagated-inputs
1129 `(("python-pbr" ,python-pbr)
1130 ("python-testtools" ,python-testtools)))
1131 (description
1132 "Testscenarios provides clean dependency injection for Python unittest
1133 style tests.")))
1134
1135 (define-public python2-testscenarios
1136 (package-with-python2 python-testscenarios))
1137
1138 ;; Testresources requires python-pbr at runtime, but pbr needs it for its
1139 ;; own tests. Hence this bootstrap variant.
1140 (define-public python-testresources-bootstrap
1141 (package
1142 (name "python-testresources-bootstrap")
1143 (version "2.0.1")
1144 (source (origin
1145 (method url-fetch)
1146 (uri (pypi-uri "testresources" version))
1147 (sha256
1148 (base32
1149 "05s4dsli9g17m1r3b1gvwicbbgq011hnpb2b9qnj27ja2n11k7gf"))))
1150 (build-system python-build-system)
1151 (arguments '(#:tests? #f))
1152 (propagated-inputs
1153 `(("python-pbr" ,python-pbr-minimal)))
1154 (home-page "https://launchpad.net/testresources")
1155 (synopsis
1156 "Pyunit extension for managing test resources")
1157 (description
1158 "This package is only here for bootstrapping purposes. Use the regular
1159 testresources package instead.")
1160 (license (list license:bsd-3 license:asl2.0)))) ; at the user's option
1161
1162 (define-public python2-testresources-bootstrap
1163 (package-with-python2 python-testresources-bootstrap))
1164
1165 (define-public python-testresources
1166 (package
1167 (inherit python-testresources-bootstrap)
1168 (name "python-testresources")
1169 (propagated-inputs
1170 `(("python-pbr" ,python-pbr)))
1171 (arguments '())
1172 (native-inputs
1173 `(("python-fixtures" ,python-fixtures)
1174 ("python-testtols" ,python-testtools)))
1175 (description
1176 "Testresources is an extension to Python's unittest to allow declarative
1177 use of resources by test cases.")))
1178
1179 (define-public python2-testresources
1180 (package-with-python2 python-testresources))
1181
1182 (define-public python-subunit-bootstrap
1183 (package
1184 (name "python-subunit-bootstrap")
1185 (version "1.3.0")
1186 (source
1187 (origin
1188 (method url-fetch)
1189 (uri (pypi-uri "python-subunit" version))
1190 (sha256
1191 (base32
1192 "1fsw8rsn1s3nklx06mayrg5rn2zbky6wwjc5z07s7rf1wjzfs1wn"))))
1193 (build-system python-build-system)
1194 (propagated-inputs
1195 `(("python-extras" ,python-extras)
1196 ("python-testtools" ,python-testtools-bootstrap)))
1197 (native-inputs
1198 `(("python-fixtures" ,python-fixtures-bootstrap)
1199 ("python-hypothesis" ,python-hypothesis)
1200 ("python-testscenarios" ,python-testscenarios-bootstrap)))
1201 (home-page "https://launchpad.net/subunit")
1202 (synopsis "Python implementation of the subunit protocol")
1203 (description
1204 "This package is here for bootstrapping purposes only. Use the regular
1205 python-subunit package instead.")
1206 (license (list license:bsd-3 license:asl2.0)))) ; at the user's option
1207
1208 (define-public python2-subunit-bootstrap
1209 (package-with-python2 python-subunit-bootstrap))
1210
1211 (define-public python-subunit
1212 (package
1213 (inherit python-subunit-bootstrap)
1214 (name "python-subunit")
1215 (propagated-inputs
1216 `(("python-extras" ,python-extras)
1217 ("python-testtools" ,python-testtools)))
1218 (native-inputs
1219 `(("python-fixtures" ,python-fixtures)
1220 ("python-hypothesis" ,python-hypothesis)
1221 ("python-testscenarios" ,python-testscenarios)))
1222 (description
1223 "Python-subunit is a Python implementation of the subunit test streaming
1224 protocol.")))
1225
1226 (define-public python2-subunit
1227 (package-with-python2 python-subunit))
1228
1229 ;; Fixtures requires python-pbr at runtime, but pbr uses fixtures for its
1230 ;; own tests. Hence this bootstrap variant.
1231 (define-public python-fixtures-bootstrap
1232 (package
1233 (name "python-fixtures-bootstrap")
1234 (version "3.0.0")
1235 (source (origin
1236 (method url-fetch)
1237 (uri (pypi-uri "fixtures" version))
1238 (sha256
1239 (base32
1240 "1vxj29bzz3rd4pcy51d05wng9q9dh4jq6wx92yklsm7i6h1ddw7w"))))
1241 (build-system python-build-system)
1242 (arguments `(#:tests? #f))
1243 (propagated-inputs
1244 `(("python-pbr-minimal" ,python-pbr-minimal)
1245 ("python-six" ,python-six)))
1246 (home-page "https://launchpad.net/python-fixtures")
1247 (synopsis "Python test fixture library")
1248 (description
1249 "This package is only used for bootstrapping. Use the regular
1250 python-fixtures package instead.")
1251 (license (list license:bsd-3 license:asl2.0)))) ; at user's option
1252
1253 (define-public python2-fixtures-bootstrap
1254 (package-with-python2 python-fixtures-bootstrap))
1255
1256 (define-public python-fixtures
1257 (package
1258 (inherit python-fixtures-bootstrap)
1259 (name "python-fixtures")
1260 (arguments
1261 '(#:phases
1262 (modify-phases %standard-phases
1263 (replace 'check
1264 (lambda _
1265 (invoke "python" "-m" "testtools.run"
1266 "fixtures.test_suite"))))))
1267 (propagated-inputs
1268 ;; Fixtures uses pbr at runtime to check versions, etc.
1269 `(("python-pbr" ,python-pbr)
1270 ("python-six" ,python-six)))
1271 (native-inputs
1272 `(("python-mock" ,python-mock)
1273 ("python-testtools" ,python-testtools-bootstrap)))
1274 (description
1275 "Fixtures provides a way to create reusable state, useful when writing
1276 Python tests.")))
1277
1278 (define-public python2-fixtures
1279 (package-with-python2 python-fixtures))
1280
1281 (define-public python-testrepository-bootstrap
1282 (package
1283 (name "python-testrepository-bootstrap")
1284 (version "0.0.20")
1285 (source
1286 (origin
1287 (method url-fetch)
1288 (uri (pypi-uri "testrepository" version))
1289 (sha256
1290 (base32
1291 "1ssqb07c277010i6gzzkbdd46gd9mrj0bi0i8vn560n2k2y4j93m"))))
1292 (build-system python-build-system)
1293 (arguments '(#:tests? #f))
1294 (propagated-inputs
1295 `(("python-fixtures" ,python-fixtures-bootstrap)
1296 ("python-subunit" ,python-subunit-bootstrap)
1297 ("python-testtools" ,python-testtools-bootstrap)))
1298 (native-inputs
1299 `(("python-mimeparse" ,python-mimeparse)))
1300 (home-page "https://launchpad.net/testrepository")
1301 (synopsis "Database for Python test results")
1302 (description
1303 "Bootstrap package for python-testrepository. Don't use this.")
1304 (license (list license:bsd-3 license:asl2.0)))) ; at user's option
1305
1306 (define-public python2-testrepository-bootstrap
1307 (package-with-python2 python-testrepository-bootstrap))
1308
1309 (define-public python-testrepository
1310 (package
1311 (inherit python-testrepository-bootstrap)
1312 (name "python-testrepository")
1313 (arguments
1314 ;; FIXME: Many tests are failing.
1315 '(#:tests? #f))
1316 (propagated-inputs
1317 `(("python-fixtures" ,python-fixtures)
1318 ("python-subunit" ,python-subunit)
1319 ("python-testtools" ,python-testtools)))
1320 (native-inputs
1321 `(("python-mimeparse" ,python-mimeparse)))
1322 (description "Testrepository provides a database of test results which can
1323 be used as part of a developer's workflow to check things such as what tests
1324 have failed since the last commit or what tests are currently failing.")))
1325
1326 (define-public python2-testrepository
1327 (package-with-python2 python-testrepository))
1328
1329 (define-public python-coverage
1330 (package
1331 (name "python-coverage")
1332 (version "4.5.3")
1333 (source
1334 (origin
1335 (method url-fetch)
1336 (uri (pypi-uri "coverage" version))
1337 (sha256
1338 (base32
1339 "02f6m073qdispn96rc616hg0rnmw1pgqzw3bgxwiwza4zf9hirlx"))))
1340 (build-system python-build-system)
1341 (arguments
1342 ;; FIXME: 95 tests failed, 539 passed, 6 skipped, 2 errors.
1343 '(#:tests? #f))
1344 (home-page "http://nedbatchelder.com/code/coverage")
1345 (synopsis "Code coverage measurement for Python")
1346 (description
1347 "Coverage measures code coverage, typically during test execution. It
1348 uses the code analysis tools and tracing hooks provided in the Python standard
1349 library to determine which lines are executable, and which have been
1350 executed.")
1351 (license license:bsd-3)))
1352
1353 (define-public python2-coverage
1354 (package-with-python2 python-coverage))
1355
1356 (define-public python-cov-core
1357 (package
1358 (name "python-cov-core")
1359 (version "1.15.0")
1360 (source
1361 (origin
1362 (method url-fetch)
1363 (uri (pypi-uri "cov-core" version))
1364 (sha256
1365 (base32
1366 "0k3np9ymh06yv1ib96sb6wfsxjkqhmik8qfsn119vnhga9ywc52a"))))
1367 (build-system python-build-system)
1368 (propagated-inputs
1369 `(("python-coverage" ,python-coverage)))
1370 (home-page "https://github.com/schlamar/cov-core")
1371 (synopsis "Coverage plugin core for pytest-cov, nose-cov and nose2-cov")
1372 (description
1373 "This is a library package for use by @code{pytest-cov}, @code{nose-cov}
1374 and @code{nose2-cov}. It is useful for developing coverage plugins for these
1375 testing frameworks.")
1376 (license license:expat)))
1377
1378 (define-public python2-cov-core
1379 (package-with-python2 python-cov-core))
1380
1381 (define-public python-codecov
1382 (package
1383 (name "python-codecov")
1384 (version "2.0.15")
1385 (source
1386 (origin
1387 (method url-fetch)
1388 (uri (pypi-uri "codecov" version))
1389 (sha256
1390 (base32
1391 "1217c0vqf7ii65635gvl27a5pfhv0r7zhrpdp9cx640hg73bgn4f"))))
1392 (build-system python-build-system)
1393 (native-inputs
1394 `(("python-unittest2" ,python-unittest2)))
1395 (propagated-inputs
1396 `(("python-coverage" ,python-coverage)
1397 ("python-requests" ,python-requests)))
1398 (home-page "http://github.com/codecov/codecov-python")
1399 (synopsis "Upload code coverage reports to @code{codecov.io}")
1400 (description
1401 "Codecov collects code coverage reports from code written in Python, Java,
1402 C/C++, R, and more, and uploads it to the @code{codecov.io} service.")
1403 (license license:asl2.0)))
1404
1405 (define-public python-testpath
1406 (package
1407 (name "python-testpath")
1408 (version "0.2")
1409 (source
1410 (origin
1411 (method git-fetch)
1412 (uri (git-reference
1413 (url "https://github.com/jupyter/testpath")
1414 (commit version)))
1415 (file-name (git-file-name name version))
1416 (sha256
1417 (base32
1418 "0r4iiizjql6ny1ln7ciw7rrbjadz1s9zrf2hl0xkgnh3ypd8936f"))))
1419 (build-system python-build-system)
1420 (arguments
1421 `(#:tests? #f ; this package does not even have a setup.py
1422 #:modules ((guix build python-build-system)
1423 (guix build utils)
1424 (srfi srfi-1))
1425 #:imported-modules (,@%python-build-system-modules
1426 (srfi srfi-1))
1427 #:phases
1428 (modify-phases %standard-phases
1429 (delete 'install)
1430 (replace 'build
1431 (lambda* (#:key inputs outputs #:allow-other-keys)
1432 (let* ((version (last
1433 (string-split (assoc-ref inputs "python") #\-)))
1434 (x.y (string-join (take (string-split version #\.) 2)
1435 "."))
1436 (dir (string-append
1437 (assoc-ref outputs "out")
1438 "/lib/python" x.y "/site-packages/testpath")))
1439 (mkdir-p dir)
1440 (copy-recursively "testpath" dir))
1441 #t)))))
1442 (home-page "https://github.com/takluyver/testpath")
1443 (synopsis "Test utilities for code working with files and commands")
1444 (description
1445 "Testpath is a collection of utilities for Python code working with files
1446 and commands. It contains functions to check things on the file system, and
1447 tools for mocking system commands and recording calls to those.")
1448 (license license:expat)))
1449
1450 (define-public python2-testpath
1451 (package-with-python2 python-testpath))
1452
1453 (define-public python-testlib
1454 (package
1455 (name "python-testlib")
1456 (version "0.6.5")
1457 (source
1458 (origin
1459 (method url-fetch)
1460 (uri (pypi-uri "testlib" version ".zip"))
1461 (sha256
1462 (base32 "1mz26cxn4x8bbgv0rn0mvj2z05y31rkc8009nvdlb3lam5b4mj3y"))))
1463 (build-system python-build-system)
1464 (native-inputs
1465 `(("unzip" ,unzip))) ; for unpacking the source
1466 (synopsis "Python micro test suite harness")
1467 (description "A micro unittest suite harness for Python.")
1468 (home-page "https://github.com/trentm/testlib")
1469 (license license:expat)))
1470
1471 (define-public python2-testlib
1472 (package-with-python2 python-testlib))
1473
1474 ;;; The software provided by this package was integrated into pytest 2.8.
1475 (define-public python-pytest-cache
1476 (package
1477 (name "python-pytest-cache")
1478 (version "1.0")
1479 (source (origin
1480 (method url-fetch)
1481 (uri (pypi-uri "pytest-cache" version))
1482 (sha256
1483 (base32
1484 "1a873fihw4rhshc722j4h6j7g3nj7xpgsna9hhg3zn6ksknnhx5y"))))
1485 (build-system python-build-system)
1486 (propagated-inputs
1487 `(("python-apipkg" ,python-apipkg)
1488 ("python-execnet" ,python-execnet)
1489 ("python-py" ,python-py)
1490 ("python-pytest" ,python-pytest)))
1491 (synopsis "Py.test plugin with mechanisms for caching across test runs")
1492 (description "The pytest-cache plugin provides tools to rerun failures from
1493 the last py.test invocation.")
1494 (home-page "https://bitbucket.org/hpk42/pytest-cache/")
1495 (license license:expat)))
1496
1497 (define-public python2-pytest-cache
1498 (package-with-python2 python-pytest-cache))
1499
1500 (define-public python-pytest-localserver
1501 (package
1502 (name "python-pytest-localserver")
1503 (version "0.5.0")
1504 (source (origin
1505 (method url-fetch)
1506 (uri (pypi-uri "pytest-localserver" version))
1507 (sha256
1508 (base32
1509 "1hpgpxrpfq5c731ndnsay2lc0y9nh2wy9fn1f83s3z8xkn82fm1s"))))
1510 (build-system python-build-system)
1511 (arguments
1512 '(#:phases
1513 (modify-phases %standard-phases
1514 (replace 'check
1515 (lambda _
1516 (invoke "py.test" "-v"))))))
1517 (native-inputs
1518 `(("python-pytest" ,python-pytest)
1519 ("python-requests" ,python-requests)
1520 ("python-six" ,python-six)))
1521 (propagated-inputs
1522 `(("python-werkzeug" ,python-werkzeug)))
1523 (synopsis "Py.test plugin to test server connections locally")
1524 (description "Pytest-localserver is a plugin for the pytest testing
1525 framework which enables you to test server connections locally.")
1526 (home-page "https://pypi.python.org/pypi/pytest-localserver")
1527 (license license:expat)))
1528
1529 (define-public python-pytest-xprocess
1530 (package
1531 (name "python-pytest-xprocess")
1532 (version "0.9.1")
1533 (source (origin
1534 (method url-fetch)
1535 (uri (pypi-uri "pytest-xprocess" version))
1536 (sha256
1537 (base32
1538 "17zlql1xqw3ywcgwwbqmw633aly99lab12hm02asr8awvg5603pp"))))
1539 (build-system python-build-system)
1540 (propagated-inputs
1541 `(("python-pytest" ,python-pytest)
1542 ("python-pytest-cache" ,python-pytest-cache)
1543 ("python-psutil" ,python-psutil)))
1544 (synopsis "Pytest plugin to manage external processes across test runs")
1545 (description "Pytest-xprocess is an experimental py.test plugin for managing
1546 processes across test runs.")
1547 (home-page "https://bitbucket.org/pytest-dev/pytest-xprocess")
1548 (license license:expat)))
1549
1550 (define-public python-pytest-subtesthack
1551 (package
1552 (name "python-pytest-subtesthack")
1553 (version "0.1.1")
1554 (source (origin
1555 (method url-fetch)
1556 (uri (pypi-uri "pytest-subtesthack" version))
1557 (sha256
1558 (base32
1559 "15kzcr5pchf3id4ikdvlv752rc0j4d912n589l4rifp8qsj19l1x"))))
1560 (build-system python-build-system)
1561 (propagated-inputs
1562 `(("python-pytest" ,python-pytest)))
1563 (synopsis "Set-up and tear-down fixtures for unit tests")
1564 (description "This plugin allows you to set up and tear down fixtures within
1565 unit test functions that use @code{py.test}. This is useful for using
1566 @command{hypothesis} inside py.test, as @command{hypothesis} will call the test
1567 function multiple times, without setting up or tearing down fixture state as is
1568 normally the case.")
1569 (home-page "https://github.com/untitaker/pytest-subtesthack/")
1570 (license license:unlicense)))
1571
1572 (define-public python2-pytest-subtesthack
1573 (package-with-python2 python-pytest-subtesthack))
1574
1575 (define-public python-pytest-sugar
1576 (package
1577 (name "python-pytest-sugar")
1578 (version "0.9.2")
1579 (source
1580 (origin
1581 (method url-fetch)
1582 (uri (pypi-uri "pytest-sugar" version))
1583 (sha256
1584 (base32
1585 "1asq7yc4g8bx2sn7yy974mhc9ywvaihasjab4inkirdwn9s7mn7w"))))
1586 (build-system python-build-system)
1587 (propagated-inputs
1588 `(("python-packaging" ,python-packaging)
1589 ("python-pytest" ,python-pytest)
1590 ("python-termcolor" ,python-termcolor)))
1591 (home-page "https://pivotfinland.com/pytest-sugar/")
1592 (synopsis "Plugin for pytest that changes the default look and feel")
1593 (description
1594 "@code{pytest-sugar} is a plugin for py.test that changes the default
1595 look and feel of py.test, using a progress bar and showing failures and errors
1596 instantly.")
1597 (license license:bsd-3)))
1598
1599 (define-public python-hypothesis
1600 (package
1601 (name "python-hypothesis")
1602 (version "4.18.3")
1603 (source (origin
1604 (method url-fetch)
1605 (uri (pypi-uri "hypothesis" version))
1606 (sha256
1607 (base32
1608 "0a35nwqyjnm4cphi43xracqpkws0ip61mndvqb1iqq7gkva83lb1"))))
1609 (build-system python-build-system)
1610 (native-inputs
1611 `(("python-flake8" ,python-flake8)
1612 ("python-pytest" ,python-pytest-bootstrap)))
1613 (propagated-inputs
1614 `(("python-attrs" ,python-attrs-bootstrap)
1615 ("python-coverage" ,python-coverage)))
1616 (synopsis "Library for property based testing")
1617 (description "Hypothesis is a library for testing your Python code against a
1618 much larger range of examples than you would ever want to write by hand. It’s
1619 based on the Haskell library, Quickcheck, and is designed to integrate
1620 seamlessly into your existing Python unit testing work flow.")
1621 (home-page "https://github.com/HypothesisWorks/hypothesis-python")
1622 (license license:mpl2.0)
1623 (properties `((python2-variant . ,(delay python2-hypothesis))))))
1624
1625 (define-public python2-hypothesis
1626 (let ((hypothesis (package-with-python2
1627 (strip-python2-variant python-hypothesis))))
1628 (package (inherit hypothesis)
1629 (propagated-inputs
1630 `(("python2-enum34" ,python2-enum34)
1631 ,@(package-propagated-inputs hypothesis))))))
1632
1633 (define-public python-lit
1634 (package
1635 (name "python-lit")
1636 (version "0.5.1")
1637 (source
1638 (origin
1639 (method url-fetch)
1640 (uri (pypi-uri "lit" version))
1641 (sha256
1642 (base32
1643 "0z651m3vkbk85y41larnsjxrszkbi58x9gzml3lb6ga7qwcrsg97"))))
1644 (build-system python-build-system)
1645 (arguments
1646 `(#:phases
1647 (modify-phases %standard-phases
1648 (replace 'check
1649 (lambda _
1650 (invoke "python" "lit.py" "tests"))))))
1651 (native-inputs
1652 `(("llvm" ,llvm)))
1653 (home-page "https://llvm.org/")
1654 (synopsis "LLVM Software Testing Tool")
1655 (description "@code{lit} is a portable tool for executing LLVM and Clang
1656 style test suites, summarizing their results, and providing indication of
1657 failures.")
1658 (license license:ncsa)))
1659
1660 (define-public python2-lit
1661 (package-with-python2 python-lit))
1662
1663 (define-public python-pytest-pep8
1664 (package
1665 (name "python-pytest-pep8")
1666 (version "1.0.6")
1667 (source (origin
1668 (method url-fetch)
1669 (uri (pypi-uri "pytest-pep8" version))
1670 (sha256
1671 (base32
1672 "06032agzhw1i9d9qlhfblnl3dw5hcyxhagn7b120zhrszbjzfbh3"))))
1673 (build-system python-build-system)
1674 (arguments
1675 `(#:tests? #f)) ; Fails with recent pytest and pep8. See upstream issues #8 and #12.
1676 (native-inputs
1677 `(("python-pytest" ,python-pytest)))
1678 (propagated-inputs
1679 `(("python-pep8" ,python-pep8)))
1680 (home-page "https://bitbucket.org/pytest-dev/pytest-pep8")
1681 (synopsis "Py.test plugin to check PEP8 requirements")
1682 (description "Pytest plugin for checking PEP8 compliance.")
1683 (license license:expat)))
1684
1685 (define-public python2-pytest-pep8
1686 (package-with-python2 python-pytest-pep8))
1687
1688 (define-public python-pytest-flakes
1689 (package
1690 (name "python-pytest-flakes")
1691 (version "1.0.1")
1692 (source (origin
1693 (method url-fetch)
1694 (uri (pypi-uri "pytest-flakes" version))
1695 (sha256
1696 (base32
1697 "0flag3n33kbhyjrhzmq990rvg4yb8hhhl0i48q9hw0ll89jp28lw"))))
1698 (build-system python-build-system)
1699 (arguments
1700 `(#:phases
1701 (modify-phases %standard-phases
1702 (delete 'check)
1703 (add-after 'install 'check
1704 (lambda* (#:key outputs inputs #:allow-other-keys)
1705 ;; It's easier to run tests after install.
1706 ;; Make installed package available for running the tests
1707 (add-installed-pythonpath inputs outputs)
1708 (invoke "py.test" "-vv"))))))
1709 (native-inputs
1710 `(("python-coverage" ,python-coverage)
1711 ("python-pytest" ,python-pytest)
1712 ("python-pytest-cache" ,python-pytest-cache)
1713 ("python-pytest-pep8" ,python-pytest-pep8)))
1714 (propagated-inputs
1715 `(("python-pyflakes" ,python-pyflakes)))
1716 (home-page "https://github.com/fschulze/pytest-flakes")
1717 (synopsis "Py.test plugin to check source code with pyflakes")
1718 (description "Pytest plugin for checking Python source code with pyflakes.")
1719 (license license:expat)))
1720
1721 (define-public python2-pytest-flakes
1722 (package-with-python2 python-pytest-flakes))
1723
1724 (define-public python2-coverage-test-runner
1725 (package
1726 (name "python2-coverage-test-runner")
1727 (version "1.15")
1728 (source
1729 (origin
1730 (method url-fetch)
1731 (uri (string-append
1732 "http://git.liw.fi/cgi-bin/cgit/cgit.cgi/"
1733 "coverage-test-runner/snapshot/coverage-test-runner-"
1734 version ".tar.gz"))
1735 (sha256
1736 (base32
1737 "1kjjb9llckycnfxag8zcvqsn4z1s3dwyw6b1n0avxydihgf30rny"))))
1738 (build-system python-build-system)
1739 (arguments
1740 `(#:python ,python-2
1741 #:phases
1742 (modify-phases %standard-phases
1743 (replace 'check
1744 (lambda _
1745 (invoke "./testrun"))))))
1746 (propagated-inputs
1747 `(("python2-coverage" ,python2-coverage)))
1748 (home-page "https://liw.fi/coverage-test-runner/")
1749 (synopsis "Python module for running unit tests")
1750 (description "@code{CoverageTestRunner} is a python module for running
1751 unit tests and failing them if the unit test module does not exercise all
1752 statements in the module it tests.")
1753 (license license:gpl3+)))
1754
1755 ;; Further releases, up to 2.4.3, have failing unit tests. See:
1756 ;; https://github.com/PyCQA/pylint/issues/3198.
1757 (define-public python-pylint
1758 (package
1759 (name "python-pylint")
1760 (version "2.3.1")
1761 (source
1762 (origin
1763 (method git-fetch)
1764 (uri (git-reference
1765 (url "https://github.com/PyCQA/pylint")
1766 (commit (string-append "pylint-" version))))
1767 (file-name (git-file-name name version))
1768 (sha256
1769 (base32
1770 "17vvzbcqmkhr4icq5p3737nbiiyj1y3g1pa08n9mb1bsnvxmqq0z"))))
1771 (build-system python-build-system)
1772 (native-inputs
1773 `(("python-pytest" ,python-pytest)
1774 ("python-pytest-runner" ,python-pytest-runner)
1775 ("python-tox" ,python-tox)))
1776 (propagated-inputs
1777 `(("python-astroid" ,python-astroid)
1778 ("python-isort" ,python-isort)
1779 ("python-mccabe" ,python-mccabe)
1780 ("python-six" ,python-six)))
1781 (home-page "https://github.com/PyCQA/pylint")
1782 (synopsis "Python source code analyzer which looks for coding standard
1783 errors")
1784 (description "Pylint is a Python source code analyzer which looks
1785 for programming errors, helps enforcing a coding standard and sniffs
1786 for some code smells (as defined in Martin Fowler's Refactoring book).
1787
1788 Pylint has many rules enabled by default, way too much to silence them
1789 all on a minimally sized program. It's highly configurable and handle
1790 pragmas to control it from within your code. Additionally, it is
1791 possible to write plugins to add your own checks.")
1792 (properties `((python2-variant . ,(delay python2-pylint))))
1793 (license license:gpl2+)))
1794
1795 ;; Python2 is not supported anymore by Pylint. See:
1796 ;; https://github.com/PyCQA/pylint/issues/1763.
1797 (define-public python2-pylint
1798 (let ((pylint (package-with-python2
1799 (strip-python2-variant python-pylint))))
1800 (package (inherit pylint)
1801 (version "1.9.5")
1802 (source
1803 (origin
1804 (method git-fetch)
1805 (uri (git-reference
1806 (url "https://github.com/PyCQA/pylint")
1807 (commit (string-append "pylint-" version))))
1808 (file-name (git-file-name (package-name pylint) version))
1809 (sha256
1810 (base32
1811 "02a89d8a47s7nfiv1ady3j0sg2sbyja3np145brarfp5x9qxz9x2"))))
1812 (arguments
1813 `(,@(package-arguments pylint)
1814 #:phases
1815 (modify-phases %standard-phases
1816 (replace 'check
1817 (lambda _
1818 ;; Somehow, tests fail if run from the build directory.
1819 (let ((work "/tmp/work"))
1820 (mkdir-p work)
1821 (setenv "PYTHONPATH"
1822 (string-append (getenv "PYTHONPATH") ":" work))
1823 (copy-recursively "." work)
1824 (with-directory-excursion "/tmp"
1825 (invoke "python" "-m" "unittest" "discover"
1826 "-s" (string-append work "/pylint/test")
1827 "-p" "*test_*.py"))))))))
1828 (native-inputs
1829 `(("python2-futures" ,python2-futures)
1830 ,@(package-native-inputs pylint)))
1831 (propagated-inputs
1832 `(("python2-backports-functools-lru-cache"
1833 ,python2-backports-functools-lru-cache)
1834 ("python2-configparser" ,python2-configparser)
1835 ,@(package-propagated-inputs pylint))))))
1836
1837 (define-public python-paramunittest
1838 (package
1839 (name "python-paramunittest")
1840 (version "0.2")
1841 (source
1842 (origin
1843 (method url-fetch)
1844 (uri (pypi-uri "ParamUnittest" version))
1845 (sha256
1846 (base32
1847 "0kp793hws5xv1wvycxq7jw2pwy36f35k39jg8hx5qikij5a0jid1"))))
1848 (build-system python-build-system)
1849 (home-page
1850 "https://github.com/rik0/ParamUnittest")
1851 (synopsis
1852 "Simple extension to have parametrized unit tests")
1853 (description
1854 "This package allows to create parametrized unit-tests that work with the standard
1855 unittest package. A parametrized test case is automatically converted to multiple test
1856 cases. Since they are TestCase subclasses, they work with other test suites that
1857 recognize TestCases.")
1858 (license license:bsd-2)))
1859
1860 (define-public python2-python-paramunittest
1861 (package-with-python2 python-paramunittest))
1862
1863 (define-public python-pytest-warnings
1864 (package
1865 (name "python-pytest-warnings")
1866 (version "0.2.0")
1867 (source
1868 (origin
1869 (method url-fetch)
1870 (uri (pypi-uri "pytest-warnings" version))
1871 (sha256
1872 (base32
1873 "0gf2dpahpl5igb7jh1sr9acj3z3gp7zahqdqb69nk6wx01c8kc1g"))))
1874 (build-system python-build-system)
1875 (propagated-inputs
1876 `(("pytest" ,python-pytest)))
1877 (home-page "https://github.com/fschulze/pytest-warnings")
1878 (synopsis "Pytest plugin to list Python warnings in pytest report")
1879 (description
1880 "Python-pytest-warnings is a pytest plugin to list Python warnings in
1881 pytest report.")
1882 (license license:expat)
1883 (properties `((python2-variant . ,(delay python2-pytest-warnings))
1884 ;; This package is part of pytest as of version 3.1.0.
1885 (superseded . ,python-pytest)))))
1886
1887 (define-public python2-pytest-warnings
1888 (package (inherit (package-with-python2
1889 (strip-python2-variant python-pytest-warnings)))
1890 (properties `((superseded . ,python2-pytest)))))
1891
1892 (define-public python-pytest-capturelog
1893 (package
1894 (name "python-pytest-capturelog")
1895 (version "0.7")
1896 (source
1897 (origin
1898 (method url-fetch)
1899 (uri (pypi-uri "pytest-capturelog" version ".tar.gz"))
1900 (sha256
1901 (base32
1902 "038049nyjl7di59ycnxvc9nydivc5m8np3hqq84j2iirkccdbs5n"))))
1903 (build-system python-build-system)
1904 (propagated-inputs
1905 `(("pytest" ,python-pytest)))
1906 (home-page "https://bitbucket.org/memedough/pytest-capturelog/overview")
1907 (synopsis "Pytest plugin to catch log messages")
1908 (description
1909 "Python-pytest-catchlog is a pytest plugin to catch log messages.")
1910 (license license:expat)))
1911
1912 (define-public python2-pytest-capturelog
1913 (package-with-python2 python-pytest-capturelog))
1914
1915 (define-public python-pytest-catchlog
1916 (package
1917 (name "python-pytest-catchlog")
1918 (version "1.2.2")
1919 (source
1920 (origin
1921 (method url-fetch)
1922 (uri (pypi-uri "pytest-catchlog" version ".zip"))
1923 (sha256
1924 (base32
1925 "1w7wxh27sbqwm4jgwrjr9c2gy384aca5jzw9c0wzhl0pmk2mvqab"))))
1926 (build-system python-build-system)
1927 (native-inputs
1928 `(("unzip" ,unzip)))
1929 (propagated-inputs
1930 `(("pytest" ,python-pytest)))
1931 (home-page "https://github.com/eisensheng/pytest-catchlog")
1932 (synopsis "Pytest plugin to catch log messages")
1933 (description
1934 "Python-pytest-catchlog is a pytest plugin to catch log messages. This is
1935 a fork of pytest-capturelog.")
1936 (license license:expat)))
1937
1938 (define-public python2-pytest-catchlog
1939 (package-with-python2 python-pytest-catchlog))
1940
1941 (define-public python-nosexcover
1942 (package
1943 (name "python-nosexcover")
1944 (version "1.0.11")
1945 (source (origin
1946 (method url-fetch)
1947 (uri (pypi-uri "nosexcover" version))
1948 (sha256
1949 (base32
1950 "10xqr12qv62k2flxwqhh8cr00cjhn7sfjrm6p35gd1x5bmjkr319"))))
1951 (build-system python-build-system)
1952 (propagated-inputs
1953 `(("python-coverage" ,python-coverage)
1954 ("python-nose" ,python-nose)))
1955 (home-page "http://github.com/cmheisel/nose-xcover")
1956 (synopsis "Extends nose.plugins.cover to add Cobertura-style XML reports")
1957 (description "Nose-xcover is a companion to the built-in
1958 @code{nose.plugins.cover}. This plugin will write out an XML coverage report
1959 to a file named coverage.xml.
1960
1961 It will honor all the options you pass to the Nose coverage plugin,
1962 especially -cover-package.")
1963 (license license:expat)))
1964
1965 (define-public python2-nosexcover
1966 (package-with-python2 python-nosexcover))
1967
1968 (define-public python-discover
1969 (package
1970 (name "python-discover")
1971 (version "0.4.0")
1972 (source
1973 (origin
1974 (method url-fetch)
1975 (uri (pypi-uri "discover" version))
1976 (sha256
1977 (base32
1978 "0y8d0zwiqar51kxj8lzmkvwc3b8kazb04gk5zcb4nzg5k68zmhq5"))))
1979 (build-system python-build-system)
1980 (home-page "http://pypi.python.org/pypi/discover/")
1981 (synopsis
1982 "Python test discovery for unittest")
1983 (description
1984 "Discover provides test discovery for unittest, a feature that has been
1985 backported from Python 2.7 for Python 2.4+.")
1986 (license license:bsd-3)))
1987
1988 (define-public python2-discover
1989 (package-with-python2 python-discover))
1990
1991 (define-public behave
1992 (package
1993 (name "behave")
1994 (version "1.2.6")
1995 (source (origin
1996 (method url-fetch)
1997 (uri (pypi-uri "behave" version))
1998 (sha256
1999 (base32
2000 "11hsz365qglvpp1m1w16239c3kiw15lw7adha49lqaakm8kj6rmr"))))
2001 (build-system python-build-system)
2002 (native-inputs
2003 `(("python-mock" ,python-mock)
2004 ("python-nose" ,python-nose)
2005 ("python-pathpy" ,python-pathpy)
2006 ("python-pyhamcrest" ,python-pyhamcrest)
2007 ("python-pytest" ,python-pytest)))
2008 (propagated-inputs
2009 `(("python-importlib-metadata" ,python-importlib-metadata)
2010 ("python-six" ,python-six)
2011 ("python-parse" ,python-parse)
2012 ("python-parse-type" ,python-parse-type)))
2013 (arguments
2014 '(#:test-target "behave_test"
2015 #:phases
2016 (modify-phases %standard-phases
2017 (add-before 'check 'fix-library-loading
2018 (lambda _
2019 ;; Otherwise, tests fail with no module named 'path'
2020 (setenv "PYTHONPATH" (string-append (getenv "PYTHONPATH") ":"
2021 (getcwd) "/tasks/_vendor"))
2022 #t)))))
2023 (home-page "https://github.com/behave/behave")
2024 (synopsis "Python behavior-driven development")
2025 (description
2026 "Behave is a tool for behavior-driven development in python.
2027 Behavior-driven development (or BDD) is an agile software development
2028 technique that encourages collaboration between developers, QA and
2029 non-technical or business participants in a software project. Behave uses
2030 tests written in a natural language style, backed up by Python code.")
2031 (license license:x11)))
2032
2033 (define-public python-behave-web-api
2034 (package
2035 (name "python-behave-web-api")
2036 (version "1.0.6")
2037 (source
2038 (origin
2039 (method url-fetch)
2040 (uri (pypi-uri "behave-web-api" version))
2041 (sha256
2042 (base32
2043 "03kpq2xsy1gab3jy0dccbxlsg7vwfy4lagss0qldwmx3xz6b3i19"))))
2044 (build-system python-build-system)
2045 (arguments
2046 `(#:phases
2047 (modify-phases %standard-phases
2048 (add-after 'unpack 'fix-dependencies
2049 (lambda _
2050 (substitute* "setup.py"
2051 (("'wheel'") "") ; We don't use it.
2052 (("'ordereddict==1.1'") "")) ; Python >= 2.7 has it built-in.
2053 #t)))))
2054 (propagated-inputs
2055 `(("behave" ,behave)
2056 ("python-requests" ,python-requests)))
2057 (home-page "https://github.com/jefersondaniel/behave-web-api")
2058 (synopsis "Provides testing for JSON APIs with Behave for Python")
2059 (description "This package provides testing utility modules for testing
2060 JSON APIs with Behave.")
2061 (license license:expat)))
2062
2063 (define-public python2-behave-web-api
2064 (package-with-python2 python-behave-web-api))
2065
2066 (define-public python-rednose
2067 (package
2068 (name "python-rednose")
2069 (version "1.2.3")
2070 (source
2071 (origin
2072 (method url-fetch)
2073 (uri (pypi-uri "rednose" version))
2074 (sha256
2075 (base32
2076 "11x5nx5b4wdq04s7vj1gcdl07jvvkfb37p0r5lg773gr5rr8mj6h"))))
2077 (build-system python-build-system)
2078 (arguments
2079 `(#:phases (modify-phases %standard-phases
2080 (add-after 'unpack 'patch-setup.py
2081 (lambda _
2082 ;; Six is only required for tests and later versions
2083 ;; work fine.
2084 (substitute* "setup.py"
2085 (("six==1.10.0") "six"))
2086 #t)))))
2087 (propagated-inputs
2088 `(("python-colorama" ,python-colorama)
2089 ("python-termstyle" ,python-termstyle)))
2090 (native-inputs
2091 `(("python-six" ,python-six)
2092 ("python-nose" ,python-nose)))
2093 (home-page "https://github.com/JBKahn/rednose")
2094 (synopsis "Colored output for Python nosetests")
2095 (description "This package provides colored output for the
2096 @command{nosetests} command of the Python Nose unit test framework.")
2097 (license license:bsd-3)))
2098
2099 (define-public python2-rednose
2100 (package-with-python2 python-rednose))
2101
2102 (define-public python-nose-randomly
2103 (package
2104 (name "python-nose-randomly")
2105 (version "1.2.6")
2106 (source
2107 (origin
2108 (method url-fetch)
2109 (uri (pypi-uri "nose-randomly" version))
2110 (sha256
2111 (base32 "0z662rqhfk4bjmg806mn4frb8nz4gbh7mrddsrhfffp1g4yklj3y"))))
2112 (build-system python-build-system)
2113 (native-inputs
2114 `(("python-nose" ,python-nose)
2115 ("python-numpy" ,python-numpy)))
2116 (home-page "https://github.com/adamchainz/nose-randomly")
2117 (synopsis
2118 "Nose plugin to randomly order tests and control random.seed")
2119 (description
2120 "This is a @code{Nose} plugin to randomly order tests which can be quite
2121 powerful in discovering hidden flaws in the tests themselves, while helping to
2122 reduce inter-test dependencies. It also helps in controlling @code{random.seed},
2123 by resetting it to a repeatable number for each test, enabling the tests to
2124 create data based on random numbers and yet remain repeatable.")
2125 (license license:bsd-3)))
2126
2127 (define-public python2-nose-randomly
2128 (package-with-python2 python-nose-randomly))
2129
2130 (define-public python-nose-timer
2131 (package
2132 (name "python-nose-timer")
2133 (version "0.7.5")
2134 (source
2135 (origin
2136 (method url-fetch)
2137 (uri (pypi-uri "nose-timer" version))
2138 (sha256
2139 (base32 "05wzkc88vbzw62pqkvhl33211b90kns0lny70b7qw62rcg4flzk4"))))
2140 (build-system python-build-system)
2141 (propagated-inputs
2142 `(("python-nose" ,python-nose)
2143 ("python-termcolor" ,python-termcolor)))
2144 (home-page "https://github.com/mahmoudimus/nose-timer")
2145 (synopsis "Timer plugin for nosetests")
2146 (description "Shows how much time was needed to run individual tests.")
2147 (license license:expat)))
2148
2149 (define-public python2-nose-timer
2150 (package-with-python2 python-nose-timer))
2151
2152 (define-public python-freezegun
2153 (package
2154 (name "python-freezegun")
2155 (version "0.3.12")
2156 (source
2157 (origin
2158 (method url-fetch)
2159 (uri (pypi-uri "freezegun" version))
2160 (sha256
2161 (base32 "1rx57v8ryjncjimg8hys9kx1r3rknvwcl4y340g20jn0sf69qk9a"))))
2162 (build-system python-build-system)
2163 (native-inputs
2164 `(("python-mock" ,python-mock)
2165 ("python-pytest" ,python-pytest)))
2166 (propagated-inputs
2167 `(("python-six" ,python-six)
2168 ("python-dateutil" ,python-dateutil)))
2169 (arguments
2170 `(#:phases
2171 (modify-phases %standard-phases
2172 ;; The tests are normally executed via `make test`, but the PyPi
2173 ;; package does not include the Makefile.
2174 (replace 'check
2175 (lambda _
2176 (invoke "pytest" "-vv"))))))
2177 (home-page "https://github.com/spulec/freezegun")
2178 (synopsis "Test utility for mocking the datetime module")
2179 (description
2180 "FreezeGun is a library that allows your python tests to travel through
2181 time by mocking the datetime module.")
2182 (license license:asl2.0)))
2183
2184 (define-public python2-freezegun
2185 (package-with-python2 python-freezegun))
2186
2187 (define-public python-flexmock
2188 (package
2189 (name "python-flexmock")
2190 (version "0.10.4")
2191 (source (origin
2192 (method url-fetch)
2193 (uri (pypi-uri "flexmock" version))
2194 (sha256
2195 (base32
2196 "0b6qw3grhgx58kxlkj7mdma7xdvlj02zabvcf7w2qifnfjwwwcsh"))))
2197 (build-system python-build-system)
2198 (home-page "https://flexmock.readthedocs.org")
2199 (synopsis "Testing library for Python")
2200 (description
2201 "flexmock is a testing library for Python that makes it easy to create
2202 mocks, stubs and fakes.")
2203 (license license:bsd-3)))
2204
2205 (define-public python2-flexmock
2206 (package-with-python2 python-flexmock))
2207
2208 (define-public python-flaky
2209 (package
2210 (name "python-flaky")
2211 (version "3.5.3")
2212 (source (origin
2213 (method url-fetch)
2214 (uri (pypi-uri "flaky" version))
2215 (sha256
2216 (base32
2217 "1nm1kjf857z5aw7v642ffsy1vwf255c6wjvmil71kckjyd0mxg8j"))))
2218 (build-system python-build-system)
2219 (arguments
2220 ;; TODO: Tests require 'coveralls' and 'genty' which are not in Guix yet.
2221 '(#:tests? #f))
2222 (home-page "https://github.com/box/flaky")
2223 (synopsis "Automatically rerun flaky tests")
2224 (description
2225 "Flaky is a plugin for @code{nose} or @code{py.test} that automatically
2226 reruns flaky tests.
2227
2228 Ideally, tests reliably pass or fail, but sometimes test fixtures must rely
2229 on components that aren't 100% reliable. With flaky, instead of removing
2230 those tests or marking them to @code{@@skip}, they can be automatically
2231 retried.")
2232 (license license:asl2.0)))
2233
2234 (define-public python2-flaky
2235 (package-with-python2 python-flaky))
2236
2237 (define-public python-pyhamcrest
2238 ;; The latest release was in 2016 and its test suite does not work with recent
2239 ;; versions of Pytest. Just take the master branch for now, which seems stable.
2240 (let ((commit "25fdc5f00bdf3084335353bc9247253098ec4cf2")
2241 (revision "0"))
2242 (package
2243 (name "python-pyhamcrest")
2244 (version (git-version "1.9.0" revision commit))
2245 (source (origin
2246 ;; Tests not distributed from pypi release.
2247 (method git-fetch)
2248 (uri (git-reference
2249 (url "https://github.com/hamcrest/PyHamcrest")
2250 (commit commit)))
2251 (file-name (git-file-name name version))
2252 (sha256
2253 (base32
2254 "1miqmhhi68vaix8sqc1lvpvbm27bacffxh5anm5cbfsvk7g9n6f3"))))
2255 (native-inputs ;all native inputs are for tests
2256 `(("python-pytest-cov" ,python-pytest-cov)
2257 ("python-mock" ,python-mock)
2258 ("python-pytest" ,python-pytest)
2259 ("python-hypothesis" ,python-hypothesis)))
2260 (propagated-inputs
2261 `(("python-six" ,python-six)))
2262 (build-system python-build-system)
2263 (arguments
2264 `(#:phases (modify-phases %standard-phases
2265 (replace 'check
2266 (lambda _
2267 (setenv "PYTHONPATH"
2268 (string-append "build/lib:"
2269 (getenv "PYTHONPATH")))
2270 (invoke "pytest" "-vv"))))))
2271 (home-page "http://hamcrest.org/")
2272 (synopsis "Hamcrest matchers for Python")
2273 (description
2274 "PyHamcrest is a framework for writing matcher objects,
2275 allowing you to declaratively define \"match\" rules.")
2276 (license license:bsd-3))))
2277
2278 (define-public python2-pyhamcrest
2279 (package-with-python2 python-pyhamcrest))
2280
2281 (define-public unittest-cpp
2282 (package
2283 (name "unittest-cpp")
2284 (version "2.0.0")
2285 (source (origin
2286 (method git-fetch)
2287 (uri (git-reference
2288 (url "https://github.com/unittest-cpp/unittest-cpp")
2289 (commit (string-append "v" version))))
2290 (file-name (git-file-name name version))
2291 (sha256
2292 (base32 "0sxb3835nly1jxn071f59fwbdzmqi74j040r81fanxyw3s1azw0i"))))
2293 (arguments
2294 `(#:tests? #f)) ; It's run after build automatically.
2295 (build-system cmake-build-system)
2296 (home-page "https://github.com/unittest-cpp/unittest-cpp")
2297 (synopsis "Lightweight unit testing framework for C++")
2298 (description "UnitTest++ is a lightweight unit testing framework for C++.
2299 It was designed to do test-driven development on a wide variety of platforms.
2300 Simplicity, portability, speed, and small footprint are all very important
2301 aspects of UnitTest++. UnitTest++ is mostly standard C++ and makes minimal use
2302 of advanced library and language features, which means it should be easily
2303 portable to just about any platform.")
2304 (license license:expat)))
2305
2306 (define-public libfaketime
2307 (package
2308 (name "libfaketime")
2309 (version "0.9.8")
2310 (home-page "https://github.com/wolfcw/libfaketime")
2311 (source (origin
2312 (method git-fetch)
2313 (uri (git-reference
2314 (url home-page)
2315 (commit (string-append "v" version))))
2316 (sha256
2317 (base32
2318 "1mfdl82ppgbdvy1ny8mb7xii7p0g7awvn4bn36jb8v4r545slmjc"))
2319 (file-name (git-file-name name version))))
2320 (build-system gnu-build-system)
2321 (arguments
2322 '(#:phases (modify-phases %standard-phases
2323 (replace 'configure
2324 (lambda* (#:key outputs #:allow-other-keys)
2325 (let ((out (assoc-ref outputs "out")))
2326 (setenv "CC" "gcc")
2327 (setenv "PREFIX" out)
2328 #t)))
2329 (add-before 'check 'pre-check
2330 (lambda _
2331 (substitute* "test/functests/test_exclude_mono.sh"
2332 (("/bin/bash") (which "bash")))
2333 #t)))
2334 #:test-target "test"))
2335 (native-inputs
2336 `(("perl" ,perl))) ;for tests
2337 (synopsis "Fake the system time for single applications")
2338 (description
2339 "The libfaketime library allows users to modify the system time that an
2340 application \"sees\". It is meant to be loaded using the dynamic linker's
2341 @code{LD_PRELOAD} environment variable. The @command{faketime} command
2342 provides a simple way to achieve this.")
2343 (license license:gpl2)))
2344
2345 (define-public umockdev
2346 (package
2347 (name "umockdev")
2348 (version "0.13.2")
2349 (source (origin
2350 (method url-fetch)
2351 (uri (string-append "https://github.com/martinpitt/umockdev/"
2352 "releases/download/" version "/"
2353 "umockdev-" version ".tar.xz"))
2354 (sha256
2355 (base32
2356 "095v3abc321s584sga04y16lcmdzsdi88h24wcrm78v7vq484g74"))))
2357 (build-system gnu-build-system)
2358 (arguments
2359 `(#:phases
2360 (modify-phases %standard-phases
2361 (add-after 'unpack 'skip-broken-test
2362 (lambda _
2363 (substitute* "tests/test-umockdev.c"
2364 (("/\\* sys/ in other dir")
2365 (string-append "return; // ")))
2366 #t)))))
2367 (native-inputs
2368 `(("vala" ,vala)
2369 ("gtk-doc" ,gtk-doc)
2370 ("pkg-config" ,pkg-config)
2371
2372 ;; For tests.
2373 ("python" ,python)
2374 ("which" ,which)))
2375 (inputs
2376 `(("glib" ,glib)
2377 ("eudev" ,eudev)
2378 ("libgudev" ,libgudev)
2379 ("gobject-introspection" ,gobject-introspection)))
2380 (home-page "https://github.com/martinpitt/umockdev/")
2381 (synopsis "Mock hardware devices for creating unit tests")
2382 (description "umockdev mocks hardware devices for creating integration
2383 tests for hardware related libraries and programs. It also provides tools to
2384 record the properties and behaviour of particular devices, and to run a
2385 program or test suite under a test bed with the previously recorded devices
2386 loaded.")
2387 (license license:lgpl2.1+)))
2388
2389 (define-public virtest
2390 ;; No releases yet, so we take the commit that "vc" expects.
2391 (let ((commit "f7d03ef39fceba168745bd29e1b20af6e7971e04")
2392 (revision "0"))
2393 (package
2394 (name "virtest")
2395 (version (git-version "0.0" revision commit))
2396 (home-page "https://github.com/mattkretz/virtest")
2397 (source (origin
2398 (method git-fetch)
2399 (uri (git-reference (url home-page) (commit commit)))
2400 (file-name (git-file-name name version))
2401 (sha256
2402 (base32
2403 "07pjyb0mk7y2w1dg1bhl26nb7416xa1mw16ifj6mmps5y6aq054l"))))
2404 (build-system cmake-build-system)
2405 (arguments
2406 `(#:phases (modify-phases %standard-phases
2407 (add-after 'unpack 'adjust-install-directory
2408 (lambda _
2409 ;; Vc is the only consumer of this library, and expects
2410 ;; to find it in "virtest/vir/" instead of "vir/vir/".
2411 (substitute* "CMakeLists.txt"
2412 (("DESTINATION include/vir")
2413 "DESTINATION include/virtest"))
2414 #t)))))
2415 (synopsis "Header-only test framework")
2416 (description
2417 "@code{virtest} is a small header-only test framework for C++. It
2418 grew out of the @dfn{Vc} project.")
2419 (license license:bsd-3))))
2420
2421 (define-public python-pyfakefs
2422 (package
2423 (name "python-pyfakefs")
2424 (version "3.5.8")
2425 (source (origin
2426 (method url-fetch)
2427 ;; We use the PyPI URL because there is no proper release
2428 ;; available from GitHub. The GitHub project only provides
2429 ;; autogenerated tarballs, which are known to change in place.
2430 (uri (pypi-uri "pyfakefs" version))
2431 (sha256
2432 (base32
2433 "0qb9jp0bqhc0dv0rn805fv99029fvx135f3bvka6scfkcl6jgllc"))
2434 (patches (search-patches
2435 "python-pyfakefs-remove-bad-test.patch"))
2436 (file-name (string-append name "-" version ".tar.gz"))))
2437 (arguments
2438 `(#:phases
2439 (modify-phases %standard-phases
2440 ;; The default test suite does not run these extra tests.
2441 (add-after 'check 'check-pytest-plugin
2442 (lambda _
2443 (invoke
2444 "python" "-m" "pytest"
2445 "pyfakefs/pytest_tests/pytest_plugin_test.py")
2446 #t)))))
2447 (native-inputs
2448 `(("python-pytest" ,python-pytest)))
2449 (build-system python-build-system)
2450 ;; Guix lint doesn't like that this is a permanent redirect to the GitHub
2451 ;; page, but the pyfakefs documentation asks us to use this specific URL
2452 ;; when linking to the project. Honor their request.
2453 (home-page "http://pyfakefs.org/")
2454 ;; TRANSLATORS: In the synopsis, "Mock" is a verb.
2455 (synopsis "Mock file system interactions in tests")
2456 (description
2457 "This package provides a Python library intended for use in automated
2458 tests. One difficulty when testing software is that the code under test might
2459 need to read or write to files in the local file system. If the file system
2460 is not set up in just the right way, it might cause a spurious error during
2461 the test. The pyfakefs library provides a solution to problems like this by
2462 mocking file system interactions. In other words, it arranges for the code
2463 under test to interact with a fake file system instead of the real file
2464 system. The code under test requires no modification to work with pyfakefs.")
2465 (license license:asl2.0)))
2466
2467 (define-public python2-pyfakefs
2468 (package-with-python2 python-pyfakefs))