forked from raohwork/marionette-go
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.drone.jsonnet
68 lines (61 loc) · 1.27 KB
/
.drone.jsonnet
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
local paths = [".", "mnsender", "mnclient", "tabmgr"];
local govers = ["1.10.8", "1.11.5", "1.12"];
local fxvers = ["66.0b9", "66.0b12"];
local tabmgrfx = ["64.0", "65.0"];
local TestTabmgrStep(go, fx) = {
name: "test-tabmgr-go"+go+"-fx"+fx,
image: "ronmi/go-firefox",
environment: {
GO_VER: go,
FX_VER: fx,
},
commands: [
"run-test.sh go test -p 2 -run TestTabManager -cover ./tabmgr",
],
volumes: [
{name: "opt", path: "/opt"},
],
};
local TestCmd(dir) = [
"run-test.sh go test -p 2 -bench . -benchmem -cover ./"+dir,
];
local TestStep(go, fx) = {
name: "test-go"+go+"-fx"+fx,
image: "ronmi/go-firefox",
environment: {
GO_VER: go,
FX_VER: fx,
},
commands: std.flattenArrays([
TestCmd(dir) for dir in paths
]),
volumes: [
{name: "opt", path: "/opt"},
],
};
local byFx(go) = [
TestStep(go, fx) for fx in fxvers
];
local byGo() = std.flattenArrays([
byFx(go) for go in govers
]);
local TestPipeline() = {
kind: "pipeline",
name: "testing",
workspace: {
base: "/go",
path: "src/github.com/raohwork/marionette-go"
},
steps: [
] + byGo() + [
TestTabmgrStep(go, fx)
for go in govers
for fx in tabmgrfx
],
volumes: [
{name: "opt", temp: {size_limit: "5g"}},
],
};
[
TestPipeline(),
]