File tree Expand file tree Collapse file tree 3 files changed +5
-10
lines changed Expand file tree Collapse file tree 3 files changed +5
-10
lines changed Original file line number Diff line number Diff line change @@ -22,4 +22,7 @@ script:
22
22
# Test that notebooks run successfully
23
23
- treon
24
24
# Naive test to check that output committed with notebook-
25
- - find . -name "*.ipynb" -exec sh test/test_output.sh "{}" \;
25
+ - >- # carefully escaped because yaml is picky
26
+ find . -name "*.ipynb" \
27
+ -exec test $(grep -oc '"outputs": ' "{}") -eq $(grep -oc '"cell_type": "code"' "{}") \; \
28
+ || exit 1
Original file line number Diff line number Diff line change @@ -12,14 +12,13 @@ on Travis.
12
12
13
13
The tests also check if output is committed with the notebook (which it should be).
14
14
This test is naive - it tests if the number of code cells in a notebook is equal to
15
- the number of cell outputs in the same notebook.
15
+ the number of cell outputs in the same notebook. (See ` .travis.yml ` .)
16
16
17
17
## Structure
18
18
19
19
.
20
20
├── README.md You are here!
21
21
├── ignore Add a directory to this file (one per line) to skip during testing
22
- ├── test_output.sh Tests that output has been committed with the notebook.
23
22
├── requirements-dev.txt Dependencies for running the tests
24
23
└── requirements.txt Dependencies for running notebooks (global)
25
24
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments