|
| 1 | +# Travis CI configuration. |
| 2 | +# Each implementation is listed using the matrix:include configuration. |
| 3 | + |
| 4 | +sudo: false |
| 5 | +dist: trusty |
1 | 6 | matrix:
|
2 | 7 | include:
|
| 8 | + # C++ implementation. Lives in cpp/, tested with bazel. |
| 9 | + - language: cpp |
| 10 | + env: OLC_PATH=cpp |
| 11 | + script: |
| 12 | + - wget -O install.sh "https://github.com/bazelbuild/bazel/releases/download/0.5.3/bazel-0.5.3-installer-linux-x86_64.sh" |
| 13 | + - chmod +x install.sh |
| 14 | + - ./install.sh --user && rm -f install.sh |
| 15 | + - ~/bin/bazel test --test_output=all ${OLC_PATH}:all |
| 16 | + |
| 17 | + # Dart implementation. Lives in dart/ |
| 18 | + - language: dart |
| 19 | + dart: stable |
| 20 | + env: OLC_PATH=dart |
| 21 | + script: |
| 22 | + - cd dart && pub get && pub run test |
| 23 | + |
| 24 | + # Go implementation. Lives in go/ |
| 25 | + - language: go |
| 26 | + go: stable |
| 27 | + env: OLC_PATH=go |
| 28 | + script: |
| 29 | + - go test ./go |
| 30 | + |
| 31 | + # Java implementation. Lives in java/, tested with bazel. |
| 32 | + - language: java |
| 33 | + jdk: oraclejdk8 |
| 34 | + env: OLC_PATH=java |
| 35 | + script: |
| 36 | + - wget -O install.sh "https://github.com/bazelbuild/bazel/releases/download/0.5.3/bazel-0.5.3-installer-linux-x86_64.sh" |
| 37 | + - chmod +x install.sh |
| 38 | + - ./install.sh --user && rm -f install.sh |
| 39 | + - ~/bin/bazel test --test_output=all ${OLC_PATH}:all |
| 40 | + |
| 41 | + # Javascript Closure library implementation. Lives in js/closure, tested with bazel. |
| 42 | + # We use language "c" because bazel will install all the dependencies we need. |
| 43 | + - language: c |
| 44 | + env: OLC_PATH=js/closure |
| 45 | + script: |
| 46 | + - wget -O install.sh "https://github.com/bazelbuild/bazel/releases/download/0.5.3/bazel-0.5.3-installer-linux-x86_64.sh" |
| 47 | + - chmod +x install.sh |
| 48 | + - ./install.sh --user && rm -f install.sh |
| 49 | + - ~/bin/bazel test --test_output=all ${OLC_PATH}:all |
| 50 | + |
| 51 | + # Javascript implementation. Lives in js/. |
3 | 52 | - language: node_js
|
4 | 53 | node_js:
|
5 | 54 | - "0.10"
|
| 55 | + env: OLC_PATH=js |
| 56 | + script: |
| 57 | + - cd js && npm install && npm test |
| 58 | + |
| 59 | + # Python implementation. Lives in python/, tested with bazel. |
| 60 | + - language: python |
| 61 | + python: 3.4 |
| 62 | + env: OLC_PATH=python |
| 63 | + script: |
| 64 | + - wget -O install.sh "https://github.com/bazelbuild/bazel/releases/download/0.5.3/bazel-0.5.3-installer-linux-x86_64.sh" |
| 65 | + - chmod +x install.sh |
| 66 | + - ./install.sh --user && rm -f install.sh |
| 67 | + - ~/bin/bazel test --test_output=all ${OLC_PATH}:all |
| 68 | + |
| 69 | + # Ruby implementation. Lives in ruby/ |
| 70 | + - language: ruby |
| 71 | + rvm: 2.2 |
| 72 | + env: OLC_PATH=ruby |
| 73 | + script: |
| 74 | + - gem install test-unit |
| 75 | + - cd ruby && ruby test/plus_codes_test.rb |
| 76 | + |
| 77 | + # Rust implementation. Lives in rust/ |
6 | 78 | - language: rust
|
| 79 | + env: OLC_PATH=rust |
7 | 80 | script:
|
8 | 81 | - cd rust/
|
9 | 82 | - cargo build --verbose --all
|
10 | 83 | - cargo test --verbose --all
|
11 |
| - |
12 |
| -# Define the list of directories to execute tests in. |
13 |
| -env: |
14 |
| - - TEST_DIR=js |
15 |
| - - TEST_DIR=go |
16 |
| - - TEST_DIR=ruby |
17 |
| - - TEST_DIR=python |
18 |
| - - TEST_DIR=rust |
19 |
| - |
20 |
| -# Test script to run. This is called once for each TEST_DIR value above. |
21 |
| -script: ./run_tests.sh |
|
0 commit comments