Skip to content

Commit fa47b8d

Browse files
Zac-HDTomAugspurger
authored andcommitted
Add initial property-based tests using Hypothesis (#22280)
* BLD: Add Hypothesis to build system * TST: Add Hypothesis tests for ticks, offsets These tests are derived from GH18761, by jbrockmendel Co-authored-by: jbrockmendel <jbrockmendel@users.noreply.github.com> * DOC: Explain Hypothesis in contributing guide * TST: remove pointless loop * TST: Improve integration of Hypothesis Responding to review from jreback on GH22280. * Final review fixes
1 parent 55d176d commit fa47b8d

25 files changed

+253
-22
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,8 @@ dist
6262
coverage.xml
6363
coverage_html_report
6464
*.pytest_cache
65+
# hypothesis test database
66+
.hypothesis/
6567

6668
# OS generated files #
6769
######################

ci/appveyor-27.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,3 +28,4 @@ dependencies:
2828
- pytest
2929
- pytest-xdist
3030
- moto
31+
- hypothesis>=3.58.0

ci/appveyor-36.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,3 +25,4 @@ dependencies:
2525
- cython>=0.28.2
2626
- pytest
2727
- pytest-xdist
28+
- hypothesis>=3.58.0

ci/check_imports.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
'html5lib',
1010
'ipython',
1111
'jinja2'
12+
'hypothesis',
1213
'lxml',
1314
'numexpr',
1415
'openpyxl',

ci/circle-27-compat.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,3 +26,4 @@ dependencies:
2626
- html5lib==1.0b2
2727
- beautifulsoup4==4.2.1
2828
- pymysql==0.6.0
29+
- hypothesis>=3.58.0

ci/circle-35-ascii.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,3 +11,5 @@ dependencies:
1111
# universal
1212
- pytest
1313
- pytest-xdist
14+
- pip:
15+
- hypothesis>=3.58.0

ci/circle-36-locale.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,3 +31,5 @@ dependencies:
3131
- pytest
3232
- pytest-xdist
3333
- moto
34+
- pip:
35+
- hypothesis>=3.58.0

ci/circle-36-locale_slow.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,3 +32,5 @@ dependencies:
3232
- pytest
3333
- pytest-xdist
3434
- moto
35+
- pip:
36+
- hypothesis>=3.58.0

ci/environment-dev.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ dependencies:
77
- NumPy
88
- flake8
99
- flake8-comprehensions
10+
- hypothesis>=3.58.0
1011
- moto
1112
- pytest>=3.6
1213
- python-dateutil>=2.5.0

ci/requirements_dev.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ Cython>=0.28.2
44
NumPy
55
flake8
66
flake8-comprehensions
7+
hypothesis>=3.58.0
78
moto
89
pytest>=3.6
910
python-dateutil>=2.5.0

0 commit comments

Comments
 (0)