forked from datastax/cpp-driver
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.yaml
80 lines (74 loc) · 2.54 KB
/
build.yaml
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
schedules:
adhoc:
schedule: adhoc
notify:
slack: cpp-driver-dev-bots
env_vars: |
CI_SCHEDULE=adhoc
commit:
schedule: per_commit
notify:
slack: cpp-driver-dev-bots
branches:
include: ["/CPP-\\d+/", "master"]
env_vars: |
CI_SCHEDULE=commit
nightly:
schedule: nightly
notify:
slack: cpp-driver-dev-bots
branches:
include: ["/CPP-\\d+/", "master"]
matrix:
exclude:
- os: ['ubuntu/trusty64/cpp', 'ubuntu/xenial64/cpp', 'centos/6-64/cpp', 'centos/7-64/cpp', 'osx/high-sierra']
env_vars: |
CI_SCHEDULE=nightly
CI_INTEGRATION_ENABLED=true
architecture:
- x64
os:
- ubuntu/bionic64/cpp
- ubuntu/trusty64/cpp
- ubuntu/xenial64/cpp
- centos/6-64/cpp
- centos/7-64/cpp
- osx/high-sierra
env:
LIBUV_VERSION: 1.34.0
build:
- script: |
. .build.sh
configure_environment
install_dependencies
build_driver 'CASS'
FUNCTIONS+=($(grep -Eoh '(^cass_\s*(\w+)\s*\()|(^dse_\s*(\w+)\s*\()' include/dse.h | awk -F '(' '{print $1}'));
FUNCTIONS+=($(grep -Eoh '^cass_\s*(\w+)\s*\(' include/cassandra.h | awk -F '(' '{print $1}'))
check_driver_exports 'build/libcassandra' "${FUNCTIONS[@]}"
build/cassandra-unit-tests --gtest_output=xml:unit-test-results.xml
if [ -f build/cassandra-integration-tests ]; then
build/cassandra-integration-tests --category=cassandra --keep-clusters --verbose --gtest_filter=DbaasTests* --gtest_output=xml:dbaas-integration-test-results.xml
fi
install_driver
test_installed_driver 'cassandra'
- xunit:
- "*test-results.xml"
package:
allow_empty: true
include: # list of files and glob paths to include in the artifact, relative to the current working directory
- packaging/packages/*
release:
matrix:
exclude:
- os: [ osx/high-sierra ]
env_vars: |
CI_SCHEDULE=release
after:
each:
- script: |
. .build.sh
DRIVER_VERSION=$(get_driver_version 'include/cassandra.h' 'CASS')
# Uploading driver packages
curl -$ARTIFACTORY_CREDS -T "{$(echo packaging/packages/cassandra-cpp-driver* | tr ' ' ',')}" "https://datastax.jfrog.io/datastax/cpp-php-drivers/cpp-driver/builds/$version/$SHA/$DISTRO/$RELEASE/cassandra/v$DRIVER_VERSION/"
# Uploading libuv packages
curl -$ARTIFACTORY_CREDS -T "{$(echo packaging/packages/libuv* | tr ' ' ',')}" "https://datastax.jfrog.io/datastax/cpp-php-drivers/cpp-driver/builds/$version/$SHA/$DISTRO/$RELEASE/dependencies/libuv/v$LIBUV_VERSION/"