2016-08-10 08:27:40 -07:00
|
|
|
# Copyright (c) 2014-present, Facebook, Inc.
|
|
|
|
# All rights reserved.
|
|
|
|
#
|
|
|
|
# This source code is licensed under the BSD-style license found in the
|
|
|
|
# LICENSE file in the root directory of this source tree. An additional grant
|
|
|
|
# of patent rights can be found in the PATENTS file in the same directory.
|
2016-08-02 08:07:04 -07:00
|
|
|
|
2016-08-10 08:27:40 -07:00
|
|
|
os: osx
|
2017-01-23 19:33:24 -08:00
|
|
|
osx_image: xcode8.2
|
2016-08-10 08:27:40 -07:00
|
|
|
language: cpp
|
2016-08-02 08:07:04 -07:00
|
|
|
compiler: clang
|
|
|
|
|
2017-02-13 05:17:34 -08:00
|
|
|
env:
|
|
|
|
- LANG=c
|
|
|
|
- LANG=java
|
|
|
|
- LANG=net
|
|
|
|
- LANG=ios
|
|
|
|
- LANG=js
|
|
|
|
|
2016-08-10 08:27:40 -07:00
|
|
|
before_install:
|
|
|
|
- brew update
|
|
|
|
- brew tap facebook/fb
|
|
|
|
- brew install buck
|
2017-02-13 05:17:34 -08:00
|
|
|
|
|
|
|
# Java
|
|
|
|
- [[ $LANG = "java" ]] && brew cask install java
|
|
|
|
- [[ $LANG = "java" ]] && export JAVA_HOME=$(/usr/libexec/java_home -v 1.8)
|
|
|
|
- [[ $LANG = "java" ]] && export PATH=$JAVA_HOME/bin:$PATH
|
|
|
|
|
|
|
|
# .NET
|
|
|
|
- [[ $LANG = "net" ]] && brew install mono
|
|
|
|
|
|
|
|
# iOS
|
|
|
|
- [[ $LANG = "ios" ]] && brew outdated xctool || brew upgrade xctool
|
|
|
|
|
|
|
|
# JavaScript
|
|
|
|
- [[ $LANG = "js" ]] && cd javascript
|
|
|
|
- [[ $LANG = "js" ]] && npm install
|
|
|
|
|
|
|
|
- script:
|
|
|
|
# C
|
|
|
|
- [[ $LANG = "c" ]] && buck test //:yoga
|
|
|
|
- [[ $LANG = "c" ]] && buck run //benchmark:benchmark
|
|
|
|
- [[ $LANG = "c" ]] && git checkout HEAD^
|
|
|
|
- [[ $LANG = "c" ]] && buck run //benchmark:benchmark
|
|
|
|
|
|
|
|
# Java
|
|
|
|
- [[ $LANG = "java" ]] && buck test //java:java
|
|
|
|
|
|
|
|
# .NET
|
|
|
|
- [[ $LANG = "net" ]] && sh csharp/tests/Facebook.Yoga/test_macos.sh
|
|
|
|
|
|
|
|
# iOS
|
|
|
|
- [[ $LANG = "ios" ]] && buck test //YogaKit:YogaKitTests --config cxx.default_platform=iphonesimulator-x86_64
|
|
|
|
|
|
|
|
# JavaScript
|
|
|
|
- [[ $LANG = "js" ]] && npm run test:all
|
|
|
|
- [[ $LANG = "js" ]] && npm run bench
|