File tree Expand file tree Collapse file tree 5 files changed +34
-5
lines changed Expand file tree Collapse file tree 5 files changed +34
-5
lines changed Original file line number Diff line number Diff line change 9
9
- PATH="/tmp/shellcheck-latest:$PATH"
10
10
script : make check
11
11
12
+ - stage : " Stack Tests"
13
+ services : docker
14
+ env : STACK=heroku-18
15
+ script : ./tests.sh
16
+
12
17
- stage : " Stack Tests"
13
18
services : docker
14
19
env : STACK=heroku-16
Original file line number Diff line number Diff line change @@ -18,6 +18,11 @@ test-heroku-16:
18
18
@docker run -v $(shell pwd) :/buildpack:ro --rm -it -e " STACK=heroku-16" heroku/heroku:16-build bash -c ' cp -r /buildpack /buildpack_test; cd /buildpack_test/; test/run;'
19
19
@echo " "
20
20
21
+ test-heroku-18 :
22
+ @echo " Running tests in docker (heroku-18)..."
23
+ @docker run -v $(shell pwd) :/buildpack:ro --rm -it -e " STACK=heroku-18" heroku/heroku:18-build bash -c ' cp -r /buildpack /buildpack_test; cd /buildpack_test/; test/run;'
24
+ @echo " "
25
+
21
26
buildenv-heroku-16 :
22
27
@echo " Creating build environment (heroku-16)..."
23
28
@echo
Original file line number Diff line number Diff line change 1
- python-2.7.13
1
+ python-3.6.6
Original file line number Diff line number Diff line change @@ -39,6 +39,11 @@ testGEOS() {
39
39
}
40
40
41
41
testNLTK () {
42
+ # NOTE: This is a RuntimeWarning emitted by Python 3's runpy.py script
43
+ # which is what is used when you call `python -m <module>`. This is due to
44
+ # how nltk imports things. It's not actually an error, but it would probably
45
+ # be bad to silence in Production.
46
+ export PYTHONWARNINGS=" ignore::RuntimeWarning"
42
47
compile " nltk"
43
48
assertCaptured " Downloading NLTK packages: city_database stopwords"
44
49
assertCapturedSuccess
@@ -76,9 +81,18 @@ testPylibmc() {
76
81
}
77
82
78
83
testPython2 () {
79
- compile " python2"
80
- assertCaptured " python-2.7.15"
81
- assertCapturedSuccess
84
+ if [[ " $STACK " == " heroku-16" ]] || [[ " $STACK " == " cedar-14" ]]; then
85
+ compile " python2"
86
+ assertCaptured " python-2.7.15"
87
+ assertCapturedSuccess
88
+ fi
89
+ }
90
+
91
+ testNoPython2 () {
92
+ if [[ " $STACK " == " heroku-18" ]]; then
93
+ compile " python2"
94
+ assertCapturedError
95
+ fi
82
96
}
83
97
84
98
testPython3 () {
Original file line number Diff line number Diff line change 13
13
if [[ " $STACK " == " heroku-16" ]]; then
14
14
make test-heroku-16
15
15
exit $?
16
- fi
16
+ fi
17
+
18
+ if [[ " $STACK " == " heroku-18" ]]; then
19
+ make test-heroku-18
20
+ exit $?
21
+ fi
You can’t perform that action at this time.
0 commit comments