gnu: emacs-svg-icon: Fix grammar.
[jackhill/guix/guix.git] / gnu / packages / python-check.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2019 Ricardo Wurmus <rekado@elephly.net>
3 ;;; Copyright © 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
4 ;;; Copyright © 2019, 2020 Efraim Flashner <efraim@flashner.co.il>
5 ;;; Copyright © 2019, 2020, 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com>
6 ;;; Copyright © 2019 Hartmut Goebel <h.goebel@crazy-compilers.com>
7 ;;; Copyright © 2020 Julien Lepiller <julien@lepiller.eu>
8 ;;; Copyright © 2020 Marius Bakke <mbakke@fastmail.com>
9 ;;; Copyright © 2020 Edouard Klein <edk@beaver-labs.com>
10 ;;; Copyright © 2020 Vinicius Monego <monego@posteo.net>
11 ;;; Copyright © 2020 Tanguy Le Carrour <tanguy@bioneland.org>
12 ;;; Copyright © 2021 Sharlatan Hellseher <sharlatanus@gmail.com>
13 ;;; Copyright © 2021 Brendan Tildesley <mail@brendan.scot>
14 ;;; Copyright © 2021 Guillaume Le Vaillant <glv@posteo.net>
15 ;;; Copyright © 2021 Bonface Munyoki Kilyungi <me@bonfacemunyoki.com>
16 ;;;
17 ;;; This file is part of GNU Guix.
18 ;;;
19 ;;; GNU Guix is free software; you can redistribute it and/or modify it
20 ;;; under the terms of the GNU General Public License as published by
21 ;;; the Free Software Foundation; either version 3 of the License, or (at
22 ;;; your option) any later version.
23 ;;;
24 ;;; GNU Guix is distributed in the hope that it will be useful, but
25 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
26 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
27 ;;; GNU General Public License for more details.
28 ;;;
29 ;;; You should have received a copy of the GNU General Public License
30 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
31
32 (define-module (gnu packages python-check)
33 #:use-module (gnu packages)
34 #:use-module (gnu packages check)
35 #:use-module (gnu packages django)
36 #:use-module (gnu packages openstack)
37 #:use-module (gnu packages python-build)
38 #:use-module (gnu packages python-web)
39 #:use-module (gnu packages python-xyz)
40 #:use-module (gnu packages web)
41 #:use-module (gnu packages xml)
42 #:use-module (guix utils)
43 #:use-module ((guix licenses) #:prefix license:)
44 #:use-module (guix packages)
45 #:use-module (guix git-download)
46 #:use-module (guix download)
47 #:use-module (guix build-system python))
48
49 (define-public python-testfixtures
50 (package
51 (name "python-testfixtures")
52 (version "6.17.1")
53 (source
54 (origin
55 (method url-fetch)
56 (uri (pypi-uri "testfixtures" version))
57 (sha256
58 (base32 "1nlv2hz20czjp4a811ichl5kwg99rh84l0mw9wq4rk3idzfs1hsy"))))
59 (build-system python-build-system)
60 (arguments
61 `(#:tests? #f)) ; PyTest-Django fails to build in master
62 (native-inputs
63 `(("python-pytest" ,python-pytest)
64 ("python-pytest-cov" ,python-pytest-cov)
65 ;;("python-pytest-django" ,python-pytest-django)
66 ("python-twine" ,python-twine)
67 ("python-wheel" ,python-wheel)))
68 (synopsis "Tests components for Python")
69 (description "Testfixtures is a collection of helpers and mock objects that
70 are useful when writing automated tests in Python.")
71 (home-page "https://testfixtures.readthedocs.io/en/latest/")
72 (license license:expat)))
73
74 (define-public python-coveralls
75 (package
76 (name "python-coveralls")
77 (version "1.11.1")
78 (home-page "https://github.com/coveralls-clients/coveralls-python")
79 (source
80 (origin
81 ;; The PyPI release lacks tests, so we pull from git instead.
82 (method git-fetch)
83 (uri (git-reference (url home-page) (commit version)))
84 (file-name (git-file-name name version))
85 (sha256
86 (base32
87 "1zr1lqdjcfwj6wcx2449mzzjq8bbhwnqcm5vdif5s8hlz35bjxkp"))))
88 (build-system python-build-system)
89 (arguments
90 '(#:phases (modify-phases %standard-phases
91 (add-before 'check 'disable-git-test
92 (lambda _
93 ;; Remove test that requires 'git' and the full checkout.
94 (delete-file "tests/git_test.py")
95 #t))
96 (replace 'check
97 (lambda* (#:key tests? #:allow-other-keys)
98 (if tests?
99 (invoke "pytest" "-vv")
100 (format #t "test suite not run~%"))
101 #t)))))
102 (propagated-inputs
103 `(("python-coverage" ,python-coverage)
104 ("python-docopt" ,python-docopt)
105 ("python-pyyaml" ,python-pyyaml)
106 ("python-requests" ,python-requests)))
107 (native-inputs
108 `(("python-mock" ,python-mock)
109 ("python-pytest" ,python-pytest)))
110 (synopsis "Show coverage stats online via coveralls.io")
111 (description
112 "Coveralls.io is a service for publishing code coverage statistics online.
113 This package provides seamless integration with coverage.py (and thus pytest,
114 nosetests, etc...) in Python projects.")
115 (license license:expat)))
116
117 (define-public python-junit-xml
118 ;; XXX: There are no tags or PyPI releases, so take the latest commit
119 ;; and use the version defined in setup.py.
120 (let ((version "1.9")
121 (commit "4bd08a272f059998cedf9b7779f944d49eba13a6")
122 (revision "0"))
123 (package
124 (name "python-junit-xml")
125 (version (git-version version revision commit))
126 (home-page "https://github.com/kyrus/python-junit-xml")
127 (source (origin
128 (method git-fetch)
129 (uri (git-reference (url home-page) (commit commit)))
130 (file-name (git-file-name name version))
131 (sha256
132 (base32
133 "0b8kbjhk3j10rk0vcniy695m3h43yip6y93h1bd6jjh0cp7s09c7"))))
134 (build-system python-build-system)
135 (arguments
136 `(#:phases (modify-phases %standard-phases
137 (replace 'check
138 (lambda _
139 (invoke "pytest" "-vv"))))))
140 (native-inputs
141 `(("python-pytest" ,python-pytest)))
142 (propagated-inputs
143 `(("python-six" ,python-six)))
144 (synopsis "Create JUnit XML test results")
145 (description
146 "This package provides a Python module for creating JUnit XML test
147 result documents that can be read by tools such as Jenkins or Bamboo.")
148 (license license:expat))))
149
150 (define-public python-vcrpy
151 (package
152 (name "python-vcrpy")
153 (version "2.0.1")
154 (source
155 (origin
156 (method url-fetch)
157 (uri (pypi-uri "vcrpy" version))
158 (sha256
159 (base32
160 "0kws7l3hci1dvjv01nxw3805q9v2mwldw58bgl8s90wqism69gjp"))))
161 (build-system python-build-system)
162 (arguments `(#:tests? #f)) ; tests require more packages for python-pytest-httpbin
163 (propagated-inputs
164 `(("python-pyyaml" ,python-pyyaml)
165 ("python-six" ,python-six)
166 ("python-wrapt" ,python-wrapt)
167 ("python-yarl" ,python-yarl)))
168 (native-inputs
169 `(("python-mock" ,python-mock)
170 ("python-pytest" ,python-pytest)
171 ("python-pytest-httpbin" ,python-pytest-httpbin)))
172 (home-page "https://github.com/kevin1024/vcrpy")
173 (synopsis "Automatically mock your HTTP interactions")
174 (description
175 "VCR.py simplifies and speeds up tests that make HTTP requests. The first
176 time you run code that is inside a VCR.py context manager or decorated function,
177 VCR.py records all HTTP interactions that take place through the libraries it
178 supports and serializes and writes them to a flat file (in yaml format by
179 default). This flat file is called a cassette. When the relevant piece of code
180 is executed again, VCR.py will read the serialized requests and responses from
181 the aforementioned cassette file, and intercept any HTTP requests that it
182 recognizes from the original test run and return the responses that corresponded
183 to those requests. This means that the requests will not actually result in
184 HTTP traffic, which confers several benefits including:
185 @enumerate
186 @item The ability to work offline
187 @item Completely deterministic tests
188 @item Increased test execution speed
189 @end enumerate
190 If the server you are testing against ever changes its API, all you need to do
191 is delete your existing cassette files, and run your tests again. VCR.py will
192 detect the absence of a cassette file and once again record all HTTP
193 interactions, which will update them to correspond to the new API.")
194 (license license:expat)))
195
196 (define-public python-pytest-ordering
197 (package
198 (name "python-pytest-ordering")
199 (version "0.6")
200 (source
201 (origin
202 ;; No tests in the PyPI tarball.
203 (method git-fetch)
204 (uri (git-reference
205 (url "https://github.com/ftobia/pytest-ordering")
206 (commit version)))
207 (file-name (git-file-name name version))
208 (sha256
209 (base32 "14msj5gyqza0gk3x7h1ivmjrwza82v84cj7jx3ks0fw9lpin7pjq"))))
210 (build-system python-build-system)
211 (arguments
212 '(#:phases
213 (modify-phases %standard-phases
214 (replace 'check
215 (lambda* (#:key inputs outputs #:allow-other-keys)
216 (add-installed-pythonpath inputs outputs)
217 (invoke "pytest" "-vv" "-k"
218 ;; This test fails because of a type mismatch of an
219 ;; argument passed to @code{pytest.main}.
220 "not test_run_marker_registered"))))))
221 (native-inputs
222 `(("python-pytest" ,python-pytest)))
223 (home-page "https://github.com/ftobia/pytest-ordering")
224 (synopsis "Pytest plugin to run your tests in a specific order")
225 (description
226 "This plugin defines Pytest markers to ensure that some tests, or groups
227 of tests run in a specific order.")
228 (license license:expat)))
229
230 (define-public python-pytest-astropy-header
231 (package
232 (name "python-pytest-astropy-header")
233 (version "0.1.2")
234 (source
235 (origin
236 (method url-fetch)
237 (uri (pypi-uri "pytest-astropy-header" version))
238 (sha256
239 (base32 "1y87agr324p6x5gvhziymxjlw54pyn4gqnd49papbl941djpkp5g"))))
240 (build-system python-build-system)
241 (native-inputs
242 `(("pytest" ,python-pytest)
243 ("setuptools-scm" ,python-setuptools-scm)))
244 (home-page "https://www.astropy.org/")
245 (synopsis
246 "Pytest plugin adding diagnostic data to the header of the test output")
247 (description
248 "This plugin package provides a way to include information about the system,
249 Python installation, and select dependencies in the header of the output when
250 running pytest. It can be used with packages that are not affiliated with the
251 Astropy project, but is optimized for use with astropy-related projects.")
252 (license license:bsd-3)))
253
254 (define-public python-pytest-astropy
255 (package
256 (name "python-pytest-astropy")
257 (version "0.8.0")
258 (source
259 (origin
260 (method url-fetch)
261 (uri (pypi-uri "pytest-astropy" version))
262 (sha256
263 (base32 "18j6z6y2fvykmcs5z0mldhhaxxn6wzpnhlm2ps7m8r5z5kmh1631"))))
264 (build-system python-build-system)
265 (arguments
266 ;; No tests provided
267 '(#:tests? #f))
268 (native-inputs
269 `(("attrs" ,python-attrs)
270 ("hypothesis" ,python-hypothesis)
271 ("pytest" ,python-pytest)
272 ("pytest-arraydiff" ,python-pytest-arraydiff)
273 ("pytest-astropy-header" ,python-pytest-astropy-header)
274 ("pytest-cov" ,python-pytest-cov)
275 ("pytest-doctestplus" ,python-pytest-doctestplus)
276 ("pytest-filter-subpackage" ,python-pytest-filter-subpackage)
277 ("pytest-mock" ,python-pytest-mock)
278 ("pytest-openfiles" ,python-pytest-openfiles)
279 ("pytest-remotedata" ,python-pytest-remotedata)
280 ("setuptools-scm" ,python-setuptools-scm)))
281 (home-page "https://github.com/astropy/pytest-astropy")
282 (synopsis
283 "Metapackage for all the testing machinery used by the Astropy Project")
284 (description
285 "This is a meta-package that pulls in the dependencies that are used by
286 astropy related packages.")
287 (license license:bsd-3)))
288
289 (define-public python-pytest-arraydiff
290 (package
291 (name "python-pytest-arraydiff")
292 (version "0.3")
293 (source
294 (origin
295 (method url-fetch)
296 (uri (pypi-uri "pytest-arraydiff" version))
297 (sha256
298 (base32 "05bcvhh2ycxa35znl8b3l9vkcmx7vwm5c3fpakbpw46c7vsn4bfy"))))
299 (build-system python-build-system)
300 (arguments
301 ;; Tests require python-astropy, which itself requires this package.
302 ;; Disable tests to avoid the circular dependency problem.
303 '(#:tests? #f))
304 (propagated-inputs
305 `(("python-numpy" ,python-numpy)
306 ("python-six" ,python-six)))
307 (home-page "https://github.com/astropy/pytest-arraydiff")
308 (synopsis "Pytest plugin to help with comparing array output from tests")
309 (description
310 "This is a py.test plugin to facilitate the generation and comparison of
311 data arrays produced during tests, in particular in cases where the arrays
312 are too large to conveniently hard-code them in the tests.")
313 (license license:bsd-3)))
314
315 (define-public python-pytest-doctestplus
316 (package
317 (name "python-pytest-doctestplus")
318 (version "0.7.0")
319 (source
320 (origin
321 (method url-fetch)
322 (uri (pypi-uri "pytest-doctestplus" version))
323 (sha256
324 (base32 "1ai9kvd7xbq2jg2h8gmkb8lqzyrxvdh4zg3vxndg149iwd1hyi7d"))))
325 (build-system python-build-system)
326 (arguments
327 '(#:phases
328 (modify-phases %standard-phases
329 (replace 'check
330 (lambda* (#:key inputs outputs #:allow-other-keys)
331 ;; Make the installed plugin discoverable by Pytest.
332 (add-installed-pythonpath inputs outputs)
333 (invoke "pytest" "-vv"))))))
334 (native-inputs
335 `(("python-pytest" ,python-pytest)))
336 (home-page "https://github.com/astropy/pytest-doctestplus")
337 (synopsis "Pytest plugin with advanced doctest features")
338 (description
339 "This package contains a plugin for the Pytest framework that provides
340 advanced doctest support and enables the testing of reStructuredText files.")
341 (license license:bsd-3)))
342
343 (define-public python-pytest-filter-subpackage
344 (package
345 (name "python-pytest-filter-subpackage")
346 (version "0.1.1")
347 (source
348 (origin
349 (method url-fetch)
350 (uri (pypi-uri "pytest-filter-subpackage" version))
351 (sha256
352 (base32 "1s4s2kd31yc65rfvl4xhy8xx806xhy59kc7668h6b6wq88xgrn5p"))))
353 (build-system python-build-system)
354 (arguments
355 '(;; One test is failing. There's an issue reported upstream. See
356 ;; https://github.com/astropy/pytest-filter-subpackage/issues/3.
357 ;; Disable it for now.
358 #:phases
359 (modify-phases %standard-phases
360 (replace 'check
361 (lambda* (#:key inputs outputs #:allow-other-keys)
362 ;; Make the installed plugin discoverable by Pytest.
363 (add-installed-pythonpath inputs outputs)
364 (invoke "pytest" "-vv" "-k" "not test_with_rst"))))))
365 (native-inputs
366 `(("python-pytest" ,python-pytest)
367 ("python-pytest-cov" ,python-pytest-cov)
368 ("python-pytest-doctestplus"
369 ,python-pytest-doctestplus)))
370 (home-page "https://github.com/astropy/pytest-filter-subpackage")
371 (synopsis "Pytest plugin for filtering based on sub-packages")
372 (description
373 "This package contains a simple plugin for the pytest framework that
374 provides a shortcut to testing all code and documentation for a given
375 sub-package.")
376 (license license:bsd-3)))
377
378 (define-public python-pytest-helpers-namespace
379 (package
380 (name "python-pytest-helpers-namespace")
381 (version "2021.3.24")
382 (source
383 (origin
384 (method url-fetch)
385 (uri (pypi-uri "pytest-helpers-namespace" version))
386 (sha256
387 (base32
388 "0pyj2d45zagmzlajzqdnkw5yz8k49pkihbydsqkzm413qnkzb38q"))))
389 (build-system python-build-system)
390 (arguments
391 '(#:phases
392 (modify-phases %standard-phases
393 (replace 'check
394 (lambda* (#:key inputs outputs #:allow-other-keys)
395 ;; Make the installed plugin discoverable by Pytest.
396 (add-installed-pythonpath inputs outputs)
397 (invoke "pytest" "-vv"))))))
398 (native-inputs
399 `(("python-pytest" ,python-pytest-6)
400 ("python-setuptools" ,python-setuptools) ; needs setuptools >= 50.3.2
401 ("python-setuptools-scm" ,python-setuptools-scm)
402 ("python-setuptools-declarative-requirements"
403 ,python-setuptools-declarative-requirements)))
404 (home-page "https://github.com/saltstack/pytest-helpers-namespace")
405 (synopsis "Pytest Helpers Namespace Plugin")
406 (description "Pytest Helpers Namespace Plugin provides a helpers pytest
407 namespace which can be used to register helper functions without requiring
408 someone to import them in their actual tests to use them.")
409 (license license:asl2.0)))
410
411 (define-public python-pytest-openfiles
412 (package
413 (name "python-pytest-openfiles")
414 (version "0.5.0")
415 (source
416 (origin
417 (method url-fetch)
418 (uri (pypi-uri "pytest-openfiles" version))
419 (sha256
420 (base32 "0n0a7fdc9m86360y96l23fvdmd6rw04bl6h5xqgl9qxfv08jk70p"))))
421 (build-system python-build-system)
422 (arguments
423 '(#:phases
424 (modify-phases %standard-phases
425 (replace 'check
426 (lambda* (#:key inputs outputs #:allow-other-keys)
427 ;; Make the installed plugin discoverable by Pytest.
428 (add-installed-pythonpath inputs outputs)
429 (invoke "pytest" "-vv"))))))
430 (native-inputs
431 `(("python-setuptools-scm" ,python-setuptools-scm)
432 ("python-pytest" ,python-pytest)))
433 (propagated-inputs
434 `(("python-psutil" ,python-psutil)))
435 (home-page "https://github.com/astropy/pytest-openfiles")
436 (synopsis "Pytest plugin for detecting inadvertent open file handles")
437 (description
438 "This package provides a plugin for the pytest framework that allows
439 developers to detect whether any file handles or other file-like objects
440 were inadvertently left open at the end of a unit test.")
441 (license license:bsd-3)))
442
443 (define-public python-pytest-remotedata
444 (package
445 (name "python-pytest-remotedata")
446 (version "0.3.2")
447 (source
448 (origin
449 (method url-fetch)
450 (uri (pypi-uri "pytest-remotedata" version))
451 (sha256
452 (base32 "1h6g6shib6z07azf12rnsa053470ggbd7hy3bnbw8nf3nza5h372"))))
453 (build-system python-build-system)
454 (arguments
455 '(#:phases
456 (modify-phases %standard-phases
457 (replace 'check
458 (lambda* (#:key inputs outputs #:allow-other-keys)
459 ;; Make the installed plugin discoverable by Pytest.
460 (add-installed-pythonpath inputs outputs)
461 (invoke "pytest" "-vv" "-k"
462 (string-append
463 ;; These tests require internet access. Disable them.
464 "not test_default_behavior"
465 " and not test_strict_with_decorator")))))))
466 (native-inputs
467 `(("python-pytest" ,python-pytest)))
468 (propagated-inputs
469 `(("python-six" ,python-six)))
470 (home-page "https://github.com/astropy/pytest-remotedata")
471 (synopsis "Pytest plugin for controlling remote data access")
472 (description
473 "This package provides a plugin for the Pytest framework that allows
474 developers to control unit tests that require access to data from the
475 internet.")
476 (license license:bsd-3)))
477
478 (define-public python-pytest-mpl
479 (package
480 (name "python-pytest-mpl")
481 (version "0.11")
482 (source
483 (origin
484 (method url-fetch)
485 (uri (pypi-uri "pytest-mpl" version))
486 (sha256
487 (base32 "1km202c1s5kcn52fx0266p06qb34va3warcby594dh6vixxa9i96"))))
488 (build-system python-build-system)
489 (arguments
490 '(#:phases
491 (modify-phases %standard-phases
492 (replace 'check
493 (lambda _
494 (invoke "pytest" "-vv"))))))
495 (native-inputs
496 `(("python-pytest" ,python-pytest)))
497 (propagated-inputs
498 `(("python-matplotlib" ,python-matplotlib)
499 ("python-pillow" ,python-pillow)))
500 (home-page "https://github.com/matplotlib/pytest-mpl")
501 (synopsis "Pytest plugin to help with testing figures output from Matplotlib")
502 (description
503 "This is a plugin to facilitate image comparison for Matplotlib figures
504 in Pytest.")
505 (license license:bsd-3)))
506
507 (define-public python-covdefaults
508 (package
509 (name "python-covdefaults")
510 (version "1.1.0")
511 (source
512 (origin
513 ;; The PyPI tarball does not include tests.
514 (method git-fetch)
515 (uri (git-reference
516 (url "https://github.com/asottile/covdefaults")
517 (commit (string-append "v" version))))
518 (file-name (git-file-name name version))
519 (sha256
520 (base32 "11a24c0wzv01n55fy4kdpnyqna4m9k0mp58kmhiaks34xw4k37hq"))))
521 (build-system python-build-system)
522 (arguments
523 `(#:phases
524 (modify-phases %standard-phases
525 (replace 'check
526 (lambda _
527 (invoke "pytest" "-vv"))))))
528 (native-inputs
529 `(("python-coverage" ,python-coverage)
530 ("python-pytest" ,python-pytest)))
531 (home-page "https://github.com/asottile/covdefaults")
532 (synopsis "Coverage plugin to provide opinionated default settings")
533 (description
534 "Covdefaults is a coverage plugin to provide opinionated default
535 settings.")
536 (license license:expat)))
537
538 (define-public python-pytest-vcr
539 ;; This commit fixes integration with pytest-5
540 (let ((commit "4d6c7b3e379a6a7cba0b8f9d20b704dc976e9f05")
541 (revision "1"))
542 (package
543 (name "python-pytest-vcr")
544 (version (git-version "1.0.2" revision commit))
545 (source
546 (origin
547 (method git-fetch)
548 (uri (git-reference
549 (url "https://github.com/ktosiek/pytest-vcr")
550 (commit commit)))
551 (file-name (git-file-name name version))
552 (sha256
553 (base32
554 "1yk988zi0la6zpcm3fff0mxf942di2jiymrfqas19nyngj5ygaqs"))))
555 (build-system python-build-system)
556 (arguments
557 `(#:phases
558 (modify-phases %standard-phases
559 (replace 'check
560 (lambda* (#:key inputs outputs #:allow-other-keys)
561 (add-installed-pythonpath inputs outputs)
562 (invoke "pytest" "tests/"))))))
563 (propagated-inputs
564 `(("python-pytest" ,python-pytest)
565 ("python-vcrpy" ,python-vcrpy)))
566 (home-page "https://github.com/ktosiek/pytest-vcr")
567 (synopsis "Plugin for managing VCR.py cassettes")
568 (description
569 "Plugin for managing VCR.py cassettes.")
570 (license license:expat))))
571
572 (define-public python-pytest-checkdocs
573 (package
574 (name "python-pytest-checkdocs")
575 (version "1.2.2")
576 (source
577 (origin
578 (method url-fetch)
579 (uri (pypi-uri "pytest-checkdocs" version))
580 (sha256
581 (base32 "0j6j1gvj6x451y3qsx4xbaq9p1w9gg3mwk7n0w80cy8vdyjkngb0"))))
582 (build-system python-build-system)
583 (propagated-inputs
584 `(("python-docutils" ,python-docutils)
585 ("python-importlib-metadata" ,python-importlib-metadata)
586 ("python-more-itertools" ,python-more-itertools)))
587 (native-inputs
588 `(("python-setuptools-scm" ,python-setuptools-scm)))
589 (home-page "https://github.com/jaraco/pytest-checkdocs")
590 (synopsis "Check the README when running tests")
591 (description
592 "This package provides a pytest plugin that checks the long description
593 of the project to ensure it renders properly.")
594 (license license:expat)))
595
596 (define-public python-re-assert
597 (package
598 (name "python-re-assert")
599 (version "1.1.0")
600 (source
601 (origin
602 ;; There are no tests in the PyPI tarball.
603 (method git-fetch)
604 (uri (git-reference
605 (url "https://github.com/asottile/re-assert")
606 (commit (string-append "v" version))))
607 (file-name (git-file-name name version))
608 (sha256
609 (base32 "1rssq4wpqmx1c17hjfx5l3sn3zmnlz9jffddiqrs4f6h7m6cadai"))))
610 (build-system python-build-system)
611 (arguments
612 `(#:phases
613 (modify-phases %standard-phases
614 (replace 'check
615 (lambda _
616 (invoke "pytest" "-vv"))))))
617 (native-inputs
618 `(("python-covdefaults" ,python-covdefaults)
619 ("python-coverage" ,python-coverage)
620 ("python-pytest" ,python-pytest)))
621 (propagated-inputs
622 `(("python-regex" ,python-regex)))
623 (home-page "https://github.com/asottile/re-assert")
624 (synopsis "Show where your regex match assertion failed")
625 (description
626 "@code{re-assert} provides a helper class to make assertions of regexes
627 simpler.")
628 (license license:expat)))
629
630 (define-public python-pytest-trio
631 (package
632 (name "python-pytest-trio")
633 (version "0.6.0")
634 (source
635 (origin
636 (method url-fetch)
637 (uri (pypi-uri "pytest-trio" version))
638 (sha256
639 (base32 "1zm8didm9h5jkqhghl9bvqs7kr7sjci282c7grhk6yhpzn8a9w4v"))))
640 (build-system python-build-system)
641 (arguments
642 `(#:phases
643 (modify-phases %standard-phases
644 (replace 'check
645 (lambda* (#:key inputs outputs #:allow-other-keys)
646 (add-installed-pythonpath inputs outputs)
647 (invoke "pytest" "-W" "error" "-ra" "-v" "--pyargs"
648 "pytest_trio" "--verbose" "--cov"))))))
649 (native-inputs
650 `(("python-hypothesis" ,python-hypothesis)
651 ("python-pytest" ,python-pytest)
652 ("python-pytest-cov" ,python-pytest-cov)))
653 (propagated-inputs
654 `(("python-trio" ,python-trio)))
655 (home-page "https://github.com/python-trio/pytest-trio")
656 (synopsis "Pytest plugin for trio")
657 (description
658 "This is a pytest plugin to help you test projects that use Trio, a
659 friendly library for concurrency and async I/O in Python.")
660 ;; Either license applies.
661 (license (list license:expat license:asl2.0))))
662
663 (define-public python-pytest-flake8
664 (package
665 (name "python-pytest-flake8")
666 (version "1.0.7")
667 (source
668 (origin
669 (method url-fetch)
670 (uri (pypi-uri "pytest-flake8" version))
671 (sha256
672 (base32
673 "0syx68xk5ss3hgp3nr2y122w0fgkzr5936ghsqrkymh3m5hrf9gh"))))
674 (build-system python-build-system)
675 (propagated-inputs
676 `(("python-flake8" ,python-flake8)))
677 (native-inputs
678 `(("python-pytest" ,python-pytest)))
679 (home-page "https://github.com/tholo/pytest-flake8")
680 (synopsis "Pytest plugin to check FLAKE8 requirements")
681 (description
682 "This package provides a pytest plugin for efficiently checking PEP8
683 compliance.")
684 (license license:bsd-3)))
685
686 (define-public python-pytest-isort
687 (package
688 (name "python-pytest-isort")
689 (version "0.3.1")
690 (source
691 (origin
692 (method url-fetch)
693 (uri (pypi-uri "pytest-isort" version))
694 (sha256
695 (base32 "06myn5hhxs5yp8dqr1yjsgcnnxnsrvsqannm00bvaw0qml6ydzjb"))))
696 (build-system python-build-system)
697 (arguments
698 `(#:phases
699 (modify-phases %standard-phases
700 (replace 'check
701 (lambda _
702 (setenv "PYTHONPATH"
703 (string-append (getcwd) ":"
704 (getenv "PYTHONPATH")))
705 (invoke "pytest"))))))
706 (propagated-inputs
707 `(("python-isort" ,python-isort)
708 ("python-pytest" ,python-pytest)))
709 (home-page "https://github.com/moccu/pytest-isort/")
710 (synopsis "Pytest plugin to check import ordering using isort")
711 (description
712 "This package provides a pytest plugin to check import ordering using
713 isort.")
714 (license license:bsd-3)))
715
716 (define-public python-pytest-shutil
717 (package
718 (name "python-pytest-shutil")
719 (version "1.7.0")
720 (source
721 (origin
722 (method url-fetch)
723 (uri (pypi-uri "pytest-shutil" version))
724 (sha256
725 (base32
726 "0q8j0ayzmnvlraml6i977ybdq4xi096djhf30n2m1rvnvrhm45nq"))))
727 (build-system python-build-system)
728 (arguments
729 `(#:phases
730 (modify-phases %standard-phases
731 (add-after 'unpack 'patch-tests
732 (lambda _
733 (mkdir "/tmp/bin")
734 (substitute* "tests/integration/test_cmdline_integration.py"
735 (("dirname = '/bin'")
736 "dirname = '/tmp/bin'")
737 (("bindir = os.path.realpath\\('/bin'\\)")
738 "bindir = os.path.realpath('/tmp/bin')"))
739 #t)))))
740 (propagated-inputs
741 `(("python-contextlib2" ,python-contextlib2)
742 ("python-execnet" ,python-execnet)
743 ("python-pathpy" ,python-pathpy)
744 ("python-termcolor" ,python-termcolor)))
745 (native-inputs
746 `(("python-mock" ,python-mock)
747 ("python-pytest" ,python-pytest)
748 ("python-setuptools-git" ,python-setuptools-git)))
749 (home-page "https://github.com/manahl/pytest-plugins")
750 (synopsis "Assorted shell and environment tools for py.test")
751 (description
752 "This package provides assorted shell and environment tools for the
753 py.test testing framework.")
754 (license license:expat)))
755
756 (define-public python-pytest-fixture-config
757 (package
758 (name "python-pytest-fixture-config")
759 (version "1.7.0")
760 (source
761 (origin
762 (method url-fetch)
763 (uri (pypi-uri "pytest-fixture-config" version))
764 (sha256
765 (base32
766 "13i1qpz22w3x4dmw8vih5jdnbqfqvl7jiqs0dg764s0zf8bp98a1"))))
767 (build-system python-build-system)
768 (native-inputs
769 `(("python-pytest" ,python-pytest)
770 ("python-setuptools-git" ,python-setuptools-git)))
771 (home-page "https://github.com/manahl/pytest-plugins")
772 (synopsis "Fixture configuration utils for py.test")
773 (description
774 "This package provides fixture configuration utilities for the py.test
775 testing framework.")
776 (license license:expat)))
777
778 (define-public python-pytest-virtualenv
779 (package
780 (name "python-pytest-virtualenv")
781 (version "1.7.0")
782 (source
783 (origin
784 (method url-fetch)
785 (uri (pypi-uri "pytest-virtualenv" version))
786 (sha256
787 (base32
788 "03w2zz3crblj1p6i8nq17946hbn3zqp9z7cfnifw47hi4a4fww12"))))
789 (build-system python-build-system)
790 (arguments
791 `(#:phases
792 (modify-phases %standard-phases
793 ;; Reference the virtualenv executable directly, to avoid the need
794 ;; for PYTHONPATH, which gets cleared when instantiating a new
795 ;; virtualenv with pytest-virtualenv.
796 (add-after 'unpack 'patch-virtualenv-executable
797 (lambda* (#:key inputs #:allow-other-keys)
798 (let* ((virtualenv (assoc-ref inputs "python-virtualenv"))
799 (virtualenv-bin (string-append virtualenv
800 "/bin/virtualenv")))
801 (substitute* "pytest_virtualenv.py"
802 (("^DEFAULT_VIRTUALENV_FIXTURE_EXECUTABLE.*$")
803 (format #f "DEFAULT_VIRTUALENV_FIXTURE_EXECUTABLE = '~a'"
804 virtualenv-bin)))
805 #t))))))
806 (propagated-inputs
807 `(("python-pytest-shutil" ,python-pytest-shutil)
808 ("python-pytest-fixture-config" ,python-pytest-fixture-config)))
809 (inputs
810 `(("python-virtualenv" ,python-virtualenv)))
811 (native-inputs
812 `(("python-mock" ,python-mock)
813 ("python-pytest" ,python-pytest)
814 ("python-setuptools-git" ,python-setuptools-git)))
815 (home-page "https://github.com/manahl/pytest-plugins")
816 (synopsis "Virtualenv fixture for py.test")
817 (description "This package provides a virtualenv fixture for the py.test
818 framework.")
819 (license license:expat)))
820
821 (define-public python-pytest-pycodestyle
822 (package
823 (name "python-pytest-pycodestyle")
824 (version "2.0.0") ;later versions require python-pytest~=5.4
825 (source
826 (origin
827 (method url-fetch)
828 (uri (pypi-uri "pytest-pycodestyle" version))
829 (sha256
830 (base32
831 "02i5gl7pm9cwxk15sn29inz3n8flpj1r3p1l110h43f2na5w8h7z"))))
832 (build-system python-build-system)
833 (propagated-inputs
834 `(("python-pycodestyle" ,python-pycodestyle)))
835 (native-inputs
836 `(("python-pytest" ,python-pytest)))
837 (home-page "https://github.com/henry0312/pytest-pycodestyle")
838 (synopsis "Pytest plugin to run pycodestyle")
839 (description "This package provides a plugin to run @code{pycodestyle}
840 for the @code{pytest} framework.")
841 (license license:expat)))
842
843 (define-public python-pytest-benchmark
844 (package
845 (name "python-pytest-benchmark")
846 (version "3.2.3")
847 (source
848 (origin
849 (method url-fetch)
850 (uri (pypi-uri "pytest-benchmark" version))
851 (sha256
852 (base32
853 "0a4mpb4j73dsyk47hd1prrjpfk4r458s102cn80rf253jg818hxd"))))
854 (build-system python-build-system)
855 (propagated-inputs
856 `(("python-py-cpuinfo" ,python-py-cpuinfo)))
857 (native-inputs
858 `(("python-pathlib2" ,python-pathlib2)
859 ("python-pytest" ,python-pytest)))
860 (home-page "https://github.com/ionelmc/pytest-benchmark")
861 (synopsis "Pytest fixture for benchmarking code")
862 (description
863 "This package provides a pytest fixture that will group the tests into
864 rounds that are calibrated to the chosen timer.")
865 (license license:bsd-2)))
866
867 (define-public python-pytest-services
868 (package
869 (name "python-pytest-services")
870 (version "1.3.1")
871 (source
872 (origin
873 (method url-fetch)
874 (uri (pypi-uri "pytest-services" version))
875 (sha256
876 (base32
877 "0b2zfv04w6m3gp2v44ifdhx22vcji069qnn95ry3zcyxib7cjnq3"))))
878 (build-system python-build-system)
879 (arguments '(#:tests? #f)) ; Tests not included in release tarball.
880 (propagated-inputs
881 `(("python-psutil" ,python-psutil)
882 ("python-requests" ,python-requests)))
883 (native-inputs
884 `(("python-pytest" ,python-pytest)))
885 (home-page "https://github.com/pytest-dev/pytest-services")
886 (synopsis "Services plugin for pytest testing framework")
887 (description
888 "This plugin provides a set of fixtures and utility functions to start
889 service processes for your tests with pytest.")
890 (license license:expat)))
891
892 (define-public python-pytest-toolbox
893 (package
894 (name "python-pytest-toolbox")
895 (version "0.4")
896 (source
897 (origin
898 ;; No tests in the PyPI tarball.
899 (method git-fetch)
900 (uri (git-reference
901 (url "https://github.com/samuelcolvin/pytest-toolbox")
902 (commit (string-append "v" version))))
903 (file-name (git-file-name name version))
904 (sha256
905 (base32 "1wqkr3g5gmqdxmhzfsxbwy8pm3cadaj6a8cxq58w9bacly4hqbh0"))))
906 (build-system python-build-system)
907 (arguments
908 '(#:phases
909 (modify-phases %standard-phases
910 (replace 'check
911 (lambda* (#:key inputs outputs #:allow-other-keys)
912 ;; Make the installed plugin discoverable by Pytest.
913 (add-installed-pythonpath inputs outputs)
914 (invoke "pytest" "-vv"))))))
915 (native-inputs
916 `(("python-coverage" ,python-coverage)
917 ("python-docutils" ,python-docutils)
918 ("python-flake8" ,python-flake8)
919 ("python-isort" ,python-isort)
920 ("python-pydantic" ,python-pydantic)
921 ("python-pyflakes" ,python-pyflakes)
922 ("python-pygments" ,python-pygments)
923 ("python-pytest" ,python-pytest)
924 ("python-pytest-cov" ,python-pytest-cov)
925 ("python-pytest-isort" ,python-pytest-isort)
926 ("python-pytest-mock" ,python-pytest-mock)
927 ("python-pytest-sugar" ,python-pytest-sugar)))
928 (home-page "https://github.com/samuelcolvin/pytest-toolbox")
929 (synopsis "Numerous useful plugins for Pytest")
930 (description
931 "Pytest Toolbox contains many useful plugins for Pytest. Among them are
932 new fixtures, new methods and new comparison objects.")
933 (license license:expat)))
934
935 (define-public python-pytest-aiohttp
936 (package
937 (name "python-pytest-aiohttp")
938 (version "0.3.0")
939 (source
940 (origin
941 (method url-fetch)
942 (uri (pypi-uri "pytest-aiohttp" version))
943 (sha256
944 (base32
945 "0kx4mbs9bflycd8x9af0idcjhdgnzri3nw1qb0vpfyb3751qaaf9"))))
946 (build-system python-build-system)
947 (native-inputs
948 `(("python-pytest" ,python-pytest)))
949 (propagated-inputs
950 `(("python-aiohttp" ,python-aiohttp)))
951 (home-page "https://github.com/aio-libs/pytest-aiohttp/")
952 (synopsis "Pytest plugin for aiohttp support")
953 (description "This package provides a pytest plugin for aiohttp support.")
954 (license license:asl2.0)))
955
956 (define-public python-nbval
957 (package
958 (name "python-nbval")
959 (version "0.9.6")
960 (source
961 (origin
962 (method url-fetch)
963 (uri (pypi-uri "nbval" version))
964 (sha256
965 (base32 "0h3xrnw0mj1srigrx2rfnd73h8s0xjycclmjs0vx7qkfyqpcvvyg"))))
966 (build-system python-build-system)
967 (arguments
968 `(#:phases
969 (modify-phases %standard-phases
970 (add-before 'check 'fix-test
971 (lambda _
972 ;; This test fails because of a mismatch in the output of LaTeX
973 ;; equation environments. Seems OK to skip.
974 (delete-file "tests/ipynb-test-samples/test-latex-pass-correctouput.ipynb")
975 #t))
976 (replace 'check
977 (lambda* (#:key inputs outputs #:allow-other-keys)
978 (add-installed-pythonpath inputs outputs)
979 (invoke "pytest" "-vv" "-k"
980 (string-append
981 ;; This only works with Pytest < 5.
982 "not nbdime_reporter"
983 ;; https://github.com/computationalmodelling/nbval/pull/148.
984 " and not test_timeouts")))))))
985 (native-inputs
986 `(("python-pytest" ,python-pytest)
987 ("python-pytest-cov" ,python-pytest-cov)
988 ("python-sympy" ,python-sympy)))
989 (propagated-inputs
990 `(("python-ipykernel" ,python-ipykernel)
991 ("python-jupyter-client" ,python-jupyter-client)
992 ("python-nbformat" ,python-nbformat)
993 ("python-six" ,python-six)))
994 (home-page "https://github.com/computationalmodelling/nbval")
995 (synopsis "Pytest plugin to validate Jupyter notebooks")
996 (description
997 "This plugin adds functionality to Pytest to recognise and collect Jupyter
998 notebooks. The intended purpose of the tests is to determine whether execution
999 of the stored inputs match the stored outputs of the @file{.ipynb} file. Whilst
1000 also ensuring that the notebooks are running without errors.")
1001 (license license:bsd-3)))
1002
1003 (define-public python-pytest-flask
1004 (package
1005 (name "python-pytest-flask")
1006 (version "1.0.0")
1007 (source
1008 (origin
1009 (method url-fetch)
1010 (uri (pypi-uri "pytest-flask" version))
1011 (sha256
1012 (base32
1013 "1hln7mwgdzfi5ma0kqfsi768l7p24jhkw8l0imhifwy08nh7hmjd"))))
1014 (build-system python-build-system)
1015 (native-inputs
1016 `(("python-flask" ,python-flask)
1017 ("python-pytest" ,python-pytest)
1018 ("python-setuptools-scm" ,python-setuptools-scm)
1019 ("python-werkzeug" ,python-werkzeug)))
1020 (home-page "https://github.com/pytest-dev/pytest-flask")
1021 (synopsis "Pytest fixtures to test Flask applications")
1022 (description
1023 "This pytest plugin provides fixtures to simplify Flask app testing.")
1024 (license license:expat)))
1025
1026 (define-public python-pytest-env
1027 (package
1028 (name "python-pytest-env")
1029 (version "0.6.2")
1030 (source
1031 (origin
1032 (method url-fetch)
1033 (uri (pypi-uri "pytest-env" version))
1034 (sha256
1035 (base32 "1hl0ln0cicdid4qjk7mv90lw9xkb0v71dlj7q7rn89vzxxm9b53y"))))
1036 (build-system python-build-system)
1037 (native-inputs
1038 `(("python-pytest" ,python-pytest)))
1039 (home-page "https://github.com/MobileDynasty/pytest-env")
1040 (synopsis "Pytest plugin that allows you to add environment variables")
1041 (description
1042 "This is a @code{py.test} plugin that enables you to set environment
1043 variables in the @file{pytest.ini} file.")
1044 (license license:expat)))
1045
1046 (define-public python-pyux
1047 (package
1048 (name "python-pyux")
1049 (version "0.0.6")
1050 (source
1051 (origin
1052 (method url-fetch)
1053 (uri (pypi-uri "pyux" version))
1054 (sha256
1055 (base32
1056 "1i17xh4dy238ibrjdgh8vn78fk5q6dj37mcznpvdfzidj57js7ca"))))
1057 (build-system python-build-system)
1058 (arguments
1059 `(#:tests? #f)) ;the mini test suite fails
1060 (home-page "https://github.com/farizrahman4u/pyux")
1061 (synopsis "Utility to check API integrity in Python libraries")
1062 (description "The pyux utility detects API changes in Python
1063 libraries.")
1064 (license license:expat)))
1065
1066 (define-public python-codacy-coverage
1067 (package
1068 (name "python-codacy-coverage")
1069 (version "1.3.11")
1070 (source
1071 (origin
1072 (method url-fetch)
1073 (uri (pypi-uri "codacy-coverage" version))
1074 (sha256
1075 (base32
1076 "1g0c0w56xdkmqb8slacyw5qhzrkp814ng3ddh2lkiij58y9m2imr"))))
1077 (build-system python-build-system)
1078 (arguments
1079 `(#:tests? #f)); no tests
1080 (propagated-inputs
1081 `(("python-check-manifest" ,python-check-manifest)))
1082 (home-page "https://github.com/codacy/python-codacy-coverage")
1083 (synopsis "Codacy coverage reporter for Python")
1084 (description "This package analyses Python test suites and reports how much
1085 of the code is covered by them. This tool is part of the Codacy suite for
1086 analysing code quality.")
1087 (license license:expat)))
1088
1089 (define-public python-httmock
1090 (package
1091 (name "python-httmock")
1092 (version "1.3.0")
1093 (source
1094 (origin
1095 (method url-fetch)
1096 (uri (pypi-uri "httmock" version))
1097 (sha256
1098 (base32
1099 "1zj1fcm0n6f0wr9mr0hmlqz9430fnr5cdwd5jkcvq9j44bnsrfz0"))))
1100 (build-system python-build-system)
1101 (arguments
1102 `(#:tests? #f)); no tests
1103 (propagated-inputs
1104 `(("python-requests" ,python-requests)))
1105 (home-page "https://github.com/patrys/httmock")
1106 (synopsis "Mocking library for requests.")
1107 (description "This package provides a library for replying fake data to
1108 Python software under test, when they make an HTTP query.")
1109 (license license:asl2.0)))
1110
1111 (define-public python-atpublic
1112 (package
1113 (name "python-atpublic")
1114 (version "1.0")
1115 (source
1116 (origin
1117 (method url-fetch)
1118 (uri (pypi-uri "atpublic" version))
1119 (sha256
1120 (base32
1121 "0i3sbxkdlbb4560rrlmwwd5y4ps7k73lp4d8wnmd7ag9k426gjkx"))))
1122 (build-system python-build-system)
1123 (arguments
1124 '(#:phases
1125 (modify-phases %standard-phases
1126 (add-before 'build 'enable-c-implementation
1127 (lambda _
1128 (setenv "ATPUBLIC_BUILD_EXTENSION" "yes")
1129 #t))
1130 (replace 'check
1131 (lambda _
1132 (invoke "python" "-m" "nose2" "-v"))))))
1133 (native-inputs
1134 `(("python-nose2" ,python-nose2)))
1135 (home-page "https://public.readthedocs.io/")
1136 (synopsis "@code{@@public} decorator for populating @code{__all__}")
1137 (description
1138 "This Python module adds a @code{@@public} decorator and function which
1139 populates a module's @code{__all__} and optionally the module globals. With
1140 it, the declaration of a name's public export semantics are not separated from
1141 the implementation of that name.")
1142 (license (list license:asl2.0
1143 license:lgpl3)))) ; only for setup_helpers.py
1144
1145 (define-public python-mypy-extensions
1146 (package
1147 (name "python-mypy-extensions")
1148 (version "0.4.3")
1149 (source
1150 (origin
1151 (method url-fetch)
1152 (uri (pypi-uri "mypy_extensions" version))
1153 (sha256
1154 (base32
1155 "1a04qsk8hd1lqns8w1j7cr0vmvbhg450di5k1i16kqxkbf7q30id"))))
1156 (build-system python-build-system)
1157 (arguments `(#:tests? #f)); no tests
1158 (home-page "https://github.com/python/mypy_extensions")
1159 (synopsis "Experimental extensions for MyPy")
1160 (description "The @code{python-mypy-extensions} module defines
1161 experimental extensions to the standard @code{typing} module that are
1162 supported by the MyPy typechecker.")
1163 (license license:expat)))
1164
1165 (define-public python-mypy
1166 (package
1167 (name "python-mypy")
1168 (version "0.790")
1169 (source
1170 (origin
1171 ;; Because of https://github.com/python/mypy/issues/9584, the
1172 ;; mypyc/analysis directory is missing in the PyPI archive, leading to
1173 ;; test failures.
1174 (method git-fetch)
1175 (uri (git-reference
1176 (url "https://github.com/python/mypy")
1177 (commit (string-append "v" version))
1178 ;; Fetch git submodules otherwise typeshed is not fetched.
1179 ;; Typeshed is a collection of Python sources type annotation
1180 ;; (data) files.
1181 (recursive? #t)))
1182 (file-name (git-file-name name version))
1183 (sha256
1184 (base32
1185 "0zq3lpdf9hphcklk40wz444h8w3dkhwa12mqba5j9lmg11klnhz7"))))
1186 (build-system python-build-system)
1187 (arguments
1188 `(#:phases
1189 (modify-phases %standard-phases
1190 (replace 'check
1191 (lambda _
1192 (invoke "pytest" "mypyc"))))))
1193 (native-inputs
1194 `(("python-attrs" ,python-attrs)
1195 ("python-flake8" ,python-flake8)
1196 ("python-flake8-bugbear" ,python-flake8-bugbear)
1197 ("python-flake8-pyi" ,python-flake8-pyi)
1198 ("python-importlib-metadata" ,python-importlib-metadata)
1199 ("python-lxml" ,python-lxml)
1200 ("python-psutil" ,python-psutil)
1201 ("python-pytest" ,python-pytest-6)
1202 ("python-pytest-cov" ,python-pytest-cov)
1203 ("python-pytest-forked" ,python-pytest-forked)
1204 ("python-pytest-xdist" ,python-pytest-xdist)
1205 ("python-virtualenv" ,python-virtualenv)))
1206 (propagated-inputs
1207 `(("python-mypy-extensions" ,python-mypy-extensions)
1208 ("python-typing-extensions" ,python-typing-extensions)
1209 ("python-typed-ast" ,python-typed-ast)))
1210 (home-page "http://www.mypy-lang.org/")
1211 (synopsis "Static type checker for Python")
1212 (description "Mypy is an optional static type checker for Python that aims
1213 to combine the benefits of dynamic (or 'duck') typing and static typing. Mypy combines
1214 the expressive power and convenience of Python with a powerful type system and
1215 compile-time type checking. Mypy type checks standard Python programs; run them using
1216 any Python VM with basically no runtime overhead.")
1217 ;; Most of the code is under MIT license; Some files are under Python Software
1218 ;; Foundation License version 2: stdlib-samples/*, mypyc/lib-rt/pythonsupport.h and
1219 ;; mypyc/lib-rt/getargs.c
1220 (license (list license:expat license:psfl))))
1221
1222 (define-public python-pyannotate
1223 (package
1224 (name "python-pyannotate")
1225 (version "1.2.0")
1226 (source
1227 (origin
1228 (method url-fetch)
1229 (uri (pypi-uri "pyannotate" version))
1230 (sha256
1231 (base32
1232 "16bm0mf7wxvy0lgmcs1p8n1ji8pnvj1jvj8zk3am70dkp825iv84"))))
1233 (build-system python-build-system)
1234 (propagated-inputs
1235 `(("python-mypy-extensions" ,python-mypy-extensions)
1236 ("python-six" ,python-six)))
1237 (home-page
1238 "https://github.com/dropbox/pyannotate")
1239 (synopsis "Auto-generate PEP-484 annotations")
1240 (description "This package, PyAnnotate, is used to auto-generate PEP-484
1241 annotations.")
1242 (license license:asl2.0)))
1243
1244 (define-public python-eradicate
1245 (package
1246 (name "python-eradicate")
1247 (version "2.0.0")
1248 (source
1249 (origin
1250 (method url-fetch)
1251 (uri (pypi-uri "eradicate" version))
1252 (sha256
1253 (base32
1254 "1j30g9jfmbfki383qxwrfds8b23yiwywj40lng4lqcf5yab4ahr7"))))
1255 (build-system python-build-system)
1256 (home-page "https://github.com/myint/eradicate")
1257 (synopsis "Remove commented-out code from Python sources")
1258 (description "The @command{eradicate} command removes commented-out code
1259 from Python files. It does this by detecting block comments that contain
1260 valid Python syntax that are likely to be commented out code.")
1261 (license license:expat)))
1262
1263 (define-public python-robber
1264 (package
1265 (name "python-robber")
1266 (version "1.1.5")
1267 (source (origin
1268 (method url-fetch)
1269 (uri (pypi-uri "robber" version))
1270 (sha256
1271 (base32
1272 "0xp5csgv2g9q38hscml6bc5i1nm4xy5lzqqiimm2drxsf0hw2nq5"))))
1273 (build-system python-build-system)
1274 ;; There are no tests in the tarball downloaded from PyPI.
1275 ;; The last version tagged in Github (0.1.0) is older than the one on PyPI.
1276 ;; Reported upstream: <https://github.com/vesln/robber.py/issues/20>.
1277 (arguments '(#:tests? #f))
1278 (propagated-inputs
1279 `(("python-mock" ,python-mock)
1280 ("python-termcolor" ,python-termcolor)))
1281 ;; URL of the fork used to generate the package available on PyPI.
1282 (home-page "https://github.com/EastAgile/robber.py")
1283 (synopsis "Test-driven development (TDD) assertion library for Python")
1284 (description "Robber is a Python assertion library for test-driven and
1285 behavior-driven development (TDD and BDD).")
1286 (license license:expat)))
1287
1288 (define-public python-stestr
1289 (package
1290 (name "python-stestr")
1291 (version "3.0.1")
1292 (source
1293 (origin
1294 (method url-fetch)
1295 (uri (pypi-uri "stestr" version))
1296 (sha256
1297 (base32
1298 "0adhqp9c9338wlvlq776k57k04lyxp38bv591afdm9gjsn2qn1zm"))))
1299 (build-system python-build-system)
1300 (arguments
1301 `(#:tests? #f)) ;to avoid circular dependencies
1302 (native-inputs
1303 `(("python-pbr" ,python-pbr)))
1304 (propagated-inputs
1305 `(("python-cliff" ,python-cliff)
1306 ("python-fixtures" ,python-fixtures)
1307 ("python-future" ,python-future)
1308 ("python-pyyaml" ,python-pyyaml)
1309 ("python-subunit" ,python-subunit)
1310 ("python-testtools" ,python-testtools)
1311 ("python-voluptuous" ,python-voluptuous)))
1312 (home-page "https://stestr.readthedocs.io/en/latest/")
1313 (synopsis "Parallel Python test runner")
1314 (description "This package provides the @command{stestr} command, a
1315 parallel Python test runner built around @code{subunit}. It is designed to
1316 execute @code{unittest} test suites using multiple processes to split up
1317 execution of a test suite. It will also store a history of all test runs to
1318 help in debugging failures and optimizing the scheduler to improve speed.")
1319 (license license:asl2.0)))
1320
1321 ;; This is only used by python-sanic
1322 (define-public python-pytest-sanic
1323 (package
1324 (name "python-pytest-sanic")
1325 (version "1.7.0")
1326 (source (origin
1327 (method url-fetch)
1328 (uri (pypi-uri "pytest-sanic" version))
1329 (sha256
1330 (base32
1331 "0hm7im77dgqfk8k34qbbfhimg8hifl4zwpa2s3mgbknrjvyw5qpx"))))
1332 (build-system python-build-system)
1333 (arguments
1334 ;; Tests depend on python-sanic.
1335 `(#:tests? #f))
1336 (propagated-inputs
1337 `(("python-httpx" ,python-httpx)
1338 ("python-async-generator"
1339 ,python-async-generator)
1340 ("python-pytest" ,python-pytest)
1341 ("python-websockets" ,python-websockets)))
1342 (home-page
1343 "https://github.com/yunstanford/pytest-sanic")
1344 (synopsis "Pytest plugin for Sanic")
1345 (description "A pytest plugin for Sanic. It helps you to test your
1346 code asynchronously.")
1347 (license license:expat)))
1348
1349 (define-public python-allpairspy
1350 (package
1351 (name "python-allpairspy")
1352 (version "2.5.0")
1353 (source
1354 (origin
1355 (method url-fetch)
1356 (uri (pypi-uri "allpairspy" version))
1357 (sha256
1358 (base32 "1c987h13dly9919d15w3h747rgn50ilnv7dginhlprxbj564hn4k"))))
1359 (build-system python-build-system)
1360 (native-inputs
1361 `(("python-pytest" ,python-pytest)
1362 ("python-pytest-runner" ,python-pytest-runner)))
1363 (home-page "https://github.com/thombashi/allpairspy")
1364 (synopsis "Pairwise test combinations generator")
1365 (description
1366 "This is a Python library for test combinations generator. The generator
1367 allows one to create a set of tests using @emph{pairwise combinations} method,
1368 reducing a number of combinations of variables into a lesser set that covers
1369 most situations.")
1370 (license license:expat)))