-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathevergreen.yml
99 lines (89 loc) · 2.7 KB
/
evergreen.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
stepback: false
command_type: system
variables:
_python: &_python /opt/mongodbtoolchain/v3/bin/python3
functions:
"fetch source":
# This clones the project being tracked into the 'src/github.com/10gen/migration-verifier' directory.
- command: git.get_project
params:
directory: src/github.com/10gen/migration-verifier
# Make an evergreen expansion file with dynamic values
- command: subprocess.exec
params:
binary: bash
args:
- "./src/github.com/10gen/migration-verifier/evergreen/generate_expansions.sh"
env:
build_tags: ${build_tags}
version_id: ${version_id}
is_patch: ${is_patch|}
triggered_by_git_tag: ${triggered_by_git_tag}
build_id: ${build_id}
build_variant: ${build_variant}
_platform: ${_platform}
_arch: ${_arch}
_os: ${_os}
evg_user: ${evg_user}
evg_key: ${evg_key}
release_aws_access_key_id: ${release_aws_access_key_id}
release_aws_secret: ${release_aws_secret}
verifier_dir: "src/github.com/10gen/migration-verifier"
# Load the expansion file to make an evergreen variable with the current unique version
- command: expansions.update
params:
file: src/github.com/10gen/migration-verifier/verifier_expansion.yml
"run unit tests":
- command: subprocess.exec
type: test
params:
binary: bash
add_expansions_to_env: true
working_dir: src/github.com/10gen/migration-verifier
args:
- "evergreen/run_python_script.sh"
- "evergreen/go_test.py"
"lint go":
- command: subprocess.exec
type: test
params:
binary: bash
add_expansions_to_env: true
working_dir: src/github.com/10gen/migration-verifier
args:
- "evergreen/run_python_script.sh"
- "evergreen/go_lint.py"
tasks:
- name: lint-go
commands:
- func: "fetch source"
- func: "lint go"
- name: test-go
commands:
- func: "fetch source"
- func: "run unit tests"
buildvariants:
#######################################
# Static Checks Buildvariant #
#######################################
- name: static-analysis-required
display_name: "! Static Analysis"
run_on:
- rhel70-small
expansions:
_platform: rhel70
tasks:
- name: lint-go
tags: ["commit-queue"]
- name: unit-tests-required
display_name: "! Unit Tests"
run_on:
- rhel70-small
expansions:
_platform: rhel70
_arch: x86_64
_os: linux
mongodb_distro: mongodb-linux-x86_64-rhel70
tasks:
- name: test-go
tags: ["commit-queue"]