Skip to content

Commit

Permalink
Added an integration test
Browse files Browse the repository at this point in the history
  • Loading branch information
LaurentRDC committed May 12, 2022
1 parent c82f906 commit 4d7e487
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 3 deletions.
11 changes: 11 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,17 @@ jobs:
exit 1
fi
pandoc-plot clean tests/issue30.md
# The idea here is to install some random package (npstreams) to
# check whether the plots will be rendered in the appropriate
# environment
python -m venv ./issue46
./issue46/bin/python -m pip install npstreams matplotlib
pandoc --filter pandoc-plot -i tests/issue46.md -t native
if [ $(ls "plots" | wc -l) != 2 ]; then
exit 1
fi
pandoc-plot clean tests/issue46.md
- name: Build documentation
run: source tools/mkmanual.sh
Expand Down
3 changes: 1 addition & 2 deletions cabal.project
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
packages: pandoc-plot.cabal
allow-newer: all
packages: pandoc-plot.cabal
1 change: 0 additions & 1 deletion pandoc-plot.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,6 @@ test-suite tests
, containers
, directory
, filepath
, hspec
, hspec-expectations
, pandoc-types >= 1.20 && <= 2
, pandoc-plot
Expand Down
9 changes: 9 additions & 0 deletions tests/issue46.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
plot-configuration: tests/fixtures/.verbose-config.yml
---

```{.matplotlib executable="./issue46/bin/python"}
import sys
print(f"sys.executable={sys.executable}", file=sys.stderr)
import npstreams
```

0 comments on commit 4d7e487

Please sign in to comment.