-
Notifications
You must be signed in to change notification settings - Fork 28
/
.travis.yml
68 lines (59 loc) · 1.69 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
language: generic
addons:
apt:
packages:
- gettext
- libcurl4-openssl-dev
- libicu-dev
- libssl-dev
- libunwind8
- zlib1g
matrix:
include:
- os: linux
dist: trusty
sudo: required
before_install:
# Install OpenSSL
- if test "$TRAVIS_OS_NAME" == "osx"; then
brew install openssl;
brew link --force openssl;
export DOTNET_SDK_URL="https://go.microsoft.com/fwlink/?linkid=843444";
else
export DOTNET_SDK_URL="https://go.microsoft.com/fwlink/?linkid=843450";
fi
- export DOTNET_INSTALL_DIR="$PWD/.dotnetcli"
# Install .NET CLI
- mkdir $DOTNET_INSTALL_DIR
- curl -L $DOTNET_SDK_URL -o dotnet_package
- tar -xvzf dotnet_package -C $DOTNET_INSTALL_DIR
# Add dotnet to PATH
- export PATH="$DOTNET_INSTALL_DIR:$PATH"
install:
# Display dotnet version info
- which dotnet;
if [ $? -eq 0 ]; then
echo "Using dotnet:";
dotnet --info;
else
echo "dotnet.exe not found"
exit 1;
fi
# Restore dependencies
- dotnet restore
before_script:
# Install consul
- if test "$TRAVIS_OS_NAME" == "osx"; then
wget 'https://releases.hashicorp.com/consul/0.7.0/consul_0.7.0_darwin_amd64.zip';
unzip "consul_0.7.0_darwin_amd64.zip";
else
wget 'https://releases.hashicorp.com/consul/0.7.0/consul_0.7.0_linux_amd64.zip';
unzip "consul_0.7.0_linux_amd64.zip";
fi
- ./consul --version
script:
# Start Consul
- ./consul agent -server -bootstrap-expect 1 -log-level err -data-dir /tmp/consul -advertise=127.0.0.1 &
# Build sample
- dotnet test test/CondenserTests/CondenserTests.csproj
- dotnet test test/Condenser.Tests.Integration/Condenser.Tests.Integration.csproj