kopia lustrzana https://github.com/jupyterhub/repo2docker
Merge pull request #401 from betatim/fix-travis
[MRG] Make travis fail when pytest failspull/410/head
commit
46f056a4e2
|
@ -17,9 +17,9 @@ script:
|
||||||
# possible issues with MANIFEST.in
|
# possible issues with MANIFEST.in
|
||||||
- pushd tests;
|
- pushd tests;
|
||||||
if [ ${REPO_TYPE} == "r" ]; then
|
if [ ${REPO_TYPE} == "r" ]; then
|
||||||
travis_wait pytest --cov repo2docker -v ${REPO_TYPE};
|
travis_wait pytest --cov repo2docker -v ${REPO_TYPE} || exit 1;
|
||||||
else
|
else
|
||||||
travis_retry pytest --cov repo2docker -v ${REPO_TYPE};
|
travis_retry pytest --cov repo2docker -v ${REPO_TYPE} || exit 1;
|
||||||
fi;
|
fi;
|
||||||
popd;
|
popd;
|
||||||
- pip install -r docs/doc-requirements.txt
|
- pip install -r docs/doc-requirements.txt
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Test that node 10 is installed and runnable.
|
Test that node 10 and npm 6 are installed and runnable.
|
||||||
|
|
|
@ -2,6 +2,9 @@
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
which node
|
which node
|
||||||
|
node --version
|
||||||
node --version | grep v10
|
node --version | grep v10
|
||||||
|
|
||||||
which npm
|
which npm
|
||||||
npm --version | grep 6.2
|
npm --version
|
||||||
|
npm --version | grep 6.4
|
||||||
|
|
|
@ -95,11 +95,10 @@ class Repo2DockerTest(pytest.Function):
|
||||||
class LocalRepo(pytest.File):
|
class LocalRepo(pytest.File):
|
||||||
def collect(self):
|
def collect(self):
|
||||||
yield Repo2DockerTest(
|
yield Repo2DockerTest(
|
||||||
self.fspath.basename, self,
|
'build', self,
|
||||||
args=[
|
args=[
|
||||||
'--appendix', 'RUN echo "appendix" > /tmp/appendix',
|
'--appendix', 'RUN echo "appendix" > /tmp/appendix',
|
||||||
self.fspath.dirname,
|
self.fspath.dirname,
|
||||||
'./verify',
|
|
||||||
],
|
],
|
||||||
)
|
)
|
||||||
yield Repo2DockerTest(
|
yield Repo2DockerTest(
|
||||||
|
@ -107,6 +106,7 @@ class LocalRepo(pytest.File):
|
||||||
args=[
|
args=[
|
||||||
'--appendix', 'RUN echo "appendix" > /tmp/appendix',
|
'--appendix', 'RUN echo "appendix" > /tmp/appendix',
|
||||||
self.fspath.dirname,
|
self.fspath.dirname,
|
||||||
|
'./verify',
|
||||||
],
|
],
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -1,8 +1,5 @@
|
||||||
System - Post-build scripts
|
postBuild and start
|
||||||
---------------------------
|
-------------------
|
||||||
|
|
||||||
It is possible to run scripts after you've built the environment specified in
|
This test checks that we can use a postBuild and start script
|
||||||
your other files. This could be used to, for example, download data or run
|
at the same time.
|
||||||
some configuration scripts.
|
|
||||||
|
|
||||||
In this example, we download and install a Jupyter Notebook extension.
|
|
||||||
|
|
|
@ -1,2 +1,6 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
|
# this value should not be visible in `verify`
|
||||||
|
export TEST_START_VAR="var is set by postBuild"
|
||||||
|
|
||||||
jupyter nbextension enable --py --sys-prefix ipyleaflet
|
jupyter nbextension enable --py --sys-prefix ipyleaflet
|
||||||
|
|
|
@ -0,0 +1,4 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
export TEST_START_VAR="var is set"
|
||||||
|
exec "$@"
|
|
@ -2,7 +2,8 @@
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
jupyter nbextension list | grep 'jupyter-leaflet' | grep enabled
|
jupyter nbextension list | grep 'jupyter-leaflet' | grep enabled
|
||||||
|
|
||||||
if [ "$TEST_START_VAR" != "var is set" ]
|
# set value of TEST_START_VAR to empty string when it is not defined
|
||||||
|
if [ "${TEST_START_VAR:-}" != "var is set" ]
|
||||||
then
|
then
|
||||||
echo "TEST_START_VAR is not set"
|
echo "TEST_START_VAR is not set"
|
||||||
exit 1
|
exit 1
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
|
|
||||||
if [ "$TEST_START_VAR" != "var is set" ]
|
# set value of TEST_START_VAR to empty string when it is not defined
|
||||||
|
if [ "${TEST_START_VAR:-}" != "var is set" ]
|
||||||
then
|
then
|
||||||
echo "TEST_START_VAR is not set"
|
echo "TEST_START_VAR is not set"
|
||||||
exit 1
|
exit 1
|
||||||
|
|
Ładowanie…
Reference in New Issue