forked from ibm-developer/generator-ibm-java
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.sh
executable file
·39 lines (39 loc) · 883 Bytes
/
build.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#!/bin/bash
echo "Build script : version 0.0.2"
if [[ $TRAVIS_PULL_REQUEST != "false" ]]; then
echo "PR detected, running all tests"
echo "Running linter"
npm run lint
retval=$?
if [ $retval != 0 ]; then
exit $retval
fi
echo "Running unit tests"
npm run test
retval=$?
if [ $retval != 0 ]; then
exit $retval
fi
echo "Running integration tests"
npm run testint
retval=$?
if [ $retval != 0 ]; then
exit $retval
fi
echo "Running coveralls"
npm run coveralls
echo "Running common tests"
npm run testcommon
retval=$?
if [ $retval != 0 ]; then
exit $retval
fi
echo "Running end to end tests"
npm run teste2e
retval=$?
if [ $retval != 0 ]; then
exit $retval
fi
else
echo "Not a PR, but a build of the branch, so not executing any tests"
fi