Skip to content

Commit 4015e0f

Browse files
Narretzpetebacondarwin
authored andcommitted
chore(travis): don't build package for the "unit" job
Source test:unit do not need built or packaged code, and, and tests:docs only need built code.
1 parent 030ae66 commit 4015e0f

File tree

1 file changed

+15
-4
lines changed

1 file changed

+15
-4
lines changed

scripts/travis/before_build.sh

+15-4
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,26 @@ set -e
44

55
yarn global add [email protected]
66

7-
mkdir -p $LOGS_DIR
7+
mkdir -p "$LOGS_DIR"
88

9-
if [ $JOB != "ci-checks" ]; then
9+
if [ "$JOB" != "ci-checks" ]; then
1010
echo "start_browser_provider"
1111
./scripts/travis/start_browser_provider.sh
1212
fi
1313

14-
if [ $JOB != "ci-checks" ]; then
14+
# ci-checks and unit tests do not run against the packaged code
15+
if [ "$JOB" != "ci-checks" ] && [ "$JOB" != "unit" ]; then
1516
grunt package
17+
fi
18+
19+
# unit runs the docs tests too which need a built version of the code
20+
if [ "$JOB" = "unit" ]; then
21+
grunt build
22+
fi
23+
24+
# check this after the package, because at this point the browser_provider
25+
# has probably arrived
26+
if [ "$JOB" != "ci-checks" ]; then
1627
echo "wait_for_browser_provider"
1728
./scripts/travis/wait_for_browser_provider.sh
18-
fi
29+
fi

0 commit comments

Comments
 (0)