forked from jython/jython
-
Notifications
You must be signed in to change notification settings - Fork 1
/
.travis.yml
102 lines (81 loc) · 2.77 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
# Build and run regression tests at Travis CI
#
# Sections of this are commented out principally for economy in running the tests.
# Runs are about 20 minutes on each host.
#
os: linux
dist: focal
language: java
addons:
apt: # only active on Linux
packages:
- ant
hostname: jyshort
jobs:
include:
- name: "openjdk8 on Linux"
dist: xenial
jdk: openjdk8
- name: "openjdk11 on Linux"
jdk: openjdk11
####
# OSX disabled because the homebrew installation of Java 8 takes nearly 20 minutes.
# (It seems impossible to stop it doing a "brew update".)
####
#- name: "openjdk@8 on macOS xcode11.6"
# os: osx
# osx_image: xcode11.6 # Supports homebrew bundle without needing update
# # https://docs.travis-ci.com/user/installing-dependencies/#installing-packages-on-macos
# addons:
# homebrew:
# taps:
# - homebrew/cask-versions # for openjdk
# packages:
# - ant
# - openjdk@8
# before_install:
# # Probe the brew Cellar
# - brew list openjdk@8
# # Make available to the JDK switcher.
# - sudo ln -sfn $(brew --prefix)/opt/openjdk@8/libexec/openjdk.jdk
# /Library/Java/JavaVirtualMachines/openjdk-8.jdk
# # Add the required JDK to the path
# - export JAVA_HOME="$(/usr/libexec/java_home -v1.8)"
# - echo $JAVA_HOME
# - export PATH="$JAVA_HOME/bin:$PATH"
- name: "openjdk11 on Windows"
os: windows
language: bash # Travis CI Windows does not yet support language: java
before_install:
# Install the required JDK and ant
- choco install openjdk11 ant
# Java is at /c/Program Files/OpenJDK/openjdk-<version-patch>/bin which is liable to change.
# Chocolatey has updated the PATH with that, but only in powershell [Environment].
# Dig out the Java path from [Environment] and translate it to Unix.
- java_exe=$(powershell -NonInteractive -Command
'$env:PATH=[Environment]::GetEnvironmentVariable("PATH","Machine");
write((Get-Command java).Path)')
- java_exe=$(cygpath "$java_exe")
- echo $java_exe
- export JAVA_HOME="${java_exe%/bin/*}"
- export PATH="$JAVA_HOME/bin:$PATH"
allow_failures:
- language: python
- os: osx # remains flakey
####
# Common part to all host OSes
####
# Install (i.e. build) Jython
install:
# Confirm versions and paths (this has been a problem)
- echo $PATH
- echo $JAVA_HOME
- ant -version
# Build Jython
- ant developer-build
# Run the regression test (tweaked for Travis in build.xml)
script:
# Echo versions of Jython, Java and OS
#- ant -emacs versions
# Fairly full regression test
- ant regrtest-ci