@@ -19,6 +19,33 @@ phases:
19
19
AWS_CONTAINER_CREDENTIALS_RELATIVE_URI= AWS_DEFAULT_REGION=
20
20
tox -e py27,py36 -- tests/unit
21
21
22
+ # run notebook test
23
+ - |
24
+ if has-matching-changes "src/*.py" "setup.py" "setup.cfg"; then
25
+ echo "running notebook test"
26
+ python setup.py sdist
27
+ aws s3 --region us-west-2 cp ./dist/sagemaker-*.tar.gz s3://sagemaker-python-sdk-pr/
28
+ aws s3 cp s3://sagemaker-mead-cli/mead-nb-test.tar.gz mead-nb-test.tar.gz
29
+ tar -xzf mead-nb-test.tar.gz
30
+ git clone --depth 1 https://github.com/awslabs/amazon-sagemaker-examples.git
31
+ JAVA_HOME=$(get-java-home)
32
+ echo "set JAVA_HOME=$JAVA_HOME"
33
+ SAGEMAKER_ROLE_ARN=$(get-sagemaker-role-arn)
34
+ echo "set SAGEMAKER_ROLE_ARN=$SAGEMAKER_ROLE_ARN"
35
+ ./runtime/bin/mead-run-nb-test \
36
+ --instance-type ml.c4.8xlarge \
37
+ --region us-west-2 \
38
+ --lifecycle-config-name install-python-sdk \
39
+ --notebook-instance-role-arn $SAGEMAKER_ROLE_ARN \
40
+ ./amazon-sagemaker-examples/sagemaker-python-sdk/tensorflow_distributed_mnist/tensorflow_batch_transform_mnist.ipynb
41
+ else
42
+ echo "skipping notebook test"
43
+ fi
44
+
22
45
# run integration tests
23
- - if-matching-changes "test/" "tests/" "src/*.py" "docker/*/Dockerfile" &&
24
- IGNORE_COVERAGE=- tox -e py27,py36 -- -n 24 --boxed tests/integ
46
+ - |
47
+ if has-matching-changes "tests/" "src/*.py" "setup.py" "setup.cfg"; then
48
+ IGNORE_COVERAGE=- tox -e py27,py36 -- -n 24 --boxed tests/integ
49
+ else
50
+ echo "skipping integration tests"
51
+ fi
0 commit comments