Skip to content

Commit 329cf41

Browse files
committed
Adding basic test configuration to tox.ini
1 parent 87be1e4 commit 329cf41

File tree

2 files changed

+42
-0
lines changed

2 files changed

+42
-0
lines changed

ignore_testing

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
content/tutorial-deep-reinforcement-learning-with-pong-from-pixels.md
2+
content/pairing.md
3+
content/tutorial-style-guide.md
4+
content/tutorial-nlp-from-scratch.md

tox.ini

+38
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
[tox]
2+
envlist =
3+
py{38,39,310}-test{,-oldestdeps,-devdeps,-predeps}{,-buildhtml}
4+
requires =
5+
pip >= 19.3.1
6+
7+
[testenv]
8+
9+
description = run tests
10+
11+
deps =
12+
# We use these files to specify all the dependencies, and below we override
13+
# versions for specific testing schenarios
14+
-rsite/requirements.txt
15+
-rrequirements.txt
16+
17+
# TODO: be clever and use the nightly wheels instead
18+
devdeps: git+https://github.com/numpy/numpy.git#egg=numpy
19+
20+
# TODO: add the oldest supported versions of all the dependencies here
21+
# oldestdeps: numpy==1.18
22+
# oldestdeps: matplotlib==3.1.2
23+
# oldestdeps: scipy==1.4
24+
25+
commands =
26+
pip freeze
27+
28+
# Ignore testing the tutorials listed in ignore_testing file
29+
!buildhtml: bash -c 'find content -name "*.md" | grep -vf ignore_testing | xargs jupytext --to notebook '
30+
31+
!buildhtml: pytest --nbval-lax --durations=10 content/
32+
buildhtml: make -C site/ SPHINXOPTS="-nWT --keep-going" html
33+
34+
pip_pre =
35+
predeps: true
36+
!predeps: false
37+
38+
skip_install = true

0 commit comments

Comments
 (0)