dart-sass/.travis.yml
2016-11-12 21:56:39 -08:00

38 lines
1.1 KiB
YAML

# Set the language to Ruby so that we can run sass-spec tests.
language: ruby
env:
- TASK=specs DART_VERSION=latest
- TASK=specs DART_VERSION=1.19.1
- TASK=analyze DART_VERSION=latest
- TASK=format DART_VERSION=latest
rvm:
- 2.3.1
cache:
directories:
- $HOME/.pub-cache
# Install the Dart SDK.
install:
- curl -o dart.zip "https://storage.googleapis.com/dart-archive/channels/stable/release/$DART_VERSION/sdk/dartsdk-linux-x64-release.zip"
- unzip dart.zip
- export PATH="$PATH:`pwd`/dart-sdk/bin"
- pub get
- if-specs() { if [ "$TASK" = specs ]; then "$@"; fi }
- if-specs export sass_spec_ref=`tool/sass-spec-ref.sh`
- if-specs git init sass-spec
- if-specs git -C sass-spec fetch git://github.com/sass/sass-spec "$sass_spec_ref" --depth 1
- if-specs git -C sass-spec checkout FETCH_HEAD
- if-specs bundle install --gemfile=sass-spec/Gemfile --jobs=3 --retry=3
script:
- if [ "$TASK" = analyze ]; then
dartanalyzer --fatal-warnings lib/;
elif [ "$TASK" = format ]; then
./tool/assert-formatted.sh;
else
(cd sass-spec; bundle exec sass-spec.rb --dart ..);
fi