Skip to content

Commit

Permalink
Try to build scalafix with travis
Browse files Browse the repository at this point in the history
  • Loading branch information
Luka Jacobowitz committed Sep 29, 2017
1 parent 50631c1 commit f6c024f
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
7 changes: 6 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ sudo: required

dist: trusty

group: edge
group: edge

git:
depth: 9999
Expand All @@ -30,6 +30,11 @@ matrix:
before_install:
- export PATH=${PATH}:./vendor/bundle

before_script:
- cd scalafix
- sbt tests/test
- cd ..

script:
- scripts/travis-publish.sh

Expand Down
9 changes: 7 additions & 2 deletions scripts/travis-publish.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,9 @@
# b. Builds and tests for the JVM using the validateJVM target, and then
# c. Produces the coverage report, and then
# d. Clean is run (as part of coverageReport), to clear down the built artifacts
# 2. The scala js build is executed, compiling the application and testing it for scala js.
# 3. The validateJVM target is executed again, due to the fact that producing coverage with the
# 2. The scalafix subdirectory is run, executing the tests inside.
# 3. The scala js build is executed, compiling the application and testing it for scala js.
# 4. The validateJVM target is executed again, due to the fact that producing coverage with the
# code coverage tool causes the byte code to be instrumented/modified to record the coverage
# metrics when the tests are executing. This causes the full JVM build to be run a second time.

Expand All @@ -34,6 +35,10 @@ free_js="$sbt_cmd validateFreeJS"
js="$core_js && $free_js && $kernel_js"
jvm="$sbt_cmd coverage validateJVM coverageReport && codecov"

cd scalafix
sbt tests/test
cd ..

if [[ $JS_BUILD == "true" ]]; then
run_cmd="$js"
else
Expand Down

0 comments on commit f6c024f

Please sign in to comment.