forked from HangfireIO/Hangfire
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
53 lines (47 loc) · 1.71 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
# Travis-CI Build for Hangfire
# see travis-ci.org for details
language: csharp
sudo: required
dist: xenial
services:
- docker
matrix:
include:
- dotnet: 3.1.100
mono: none
os: linux
- dotnet: 3.1.100
mono: none
os: osx
- mono: latest
os: linux
- mono: beta
os: osx
before_script:
- if hash docker 2>/dev/null;
then
sudo docker run --name=mssql2017 -e 'ACCEPT_EULA=Y' -e 'MSSQL_SA_PASSWORD=Password12!' -p 1433:1433 -d microsoft/mssql-server-linux:2017-latest;
export Hangfire_SqlServer_ConnectionStringTemplate="Server=tcp:127.0.0.1,1433;Database={0};User Id=sa;Password=Password12!";
fi
# Run the build script
# Add tests for MSSQL in Mono when https://github.com/mono/mono/issues/16440 is fixed
script:
- if hash mono 2>/dev/null;
then
travis_retry nuget install .nuget/packages.config -OutputDirectory packages;
travis_retry nuget restore Hangfire.sln;
msbuild /p:Configuration=Release /verbosity:minimal Hangfire.sln;
mono ./packages/xunit.runner.console.2.2.0/tools/xunit.console.exe ./tests/Hangfire.Core.Tests/bin/Release/net452/Hangfire.Core.Tests.dll;
else
set -e;
dotnet test -c Release -f netcoreapp3.1 tests/Hangfire.Core.Tests/Hangfire.Core.Tests.csproj;
if hash docker 2>/dev/null;
then
dotnet test -c Release -f netcoreapp3.1 tests/Hangfire.SqlServer.Tests/Hangfire.SqlServer.Tests.csproj;
fi
fi
notifications:
slack:
secure: LZuLPI1Cj9DgNAtFsZ/zk1fWBDS2PTHHIjvtCV3Fa9qNajzna2qR6Ui3sM/FQirvoXp0JHAqNYkFDI216YativqabWXZp6dQgw3u64bdlc1IWxQ4C6XHpp8WVe1wsNi19vfwKVHfvaNXpvNp9OGHXkmoTS74arRtPhpzSXO/IXw=
on_success: change
on_failure: always