-
Notifications
You must be signed in to change notification settings - Fork 401
/
azure-pipelines.yml
112 lines (99 loc) · 2.67 KB
/
azure-pipelines.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
100
101
102
103
104
105
106
107
108
109
110
111
112
trigger:
- main
pr:
- master
pool:
vmImage: 'ubuntu-latest'
stages:
- stage: UnitTests
displayName: Run unit tests
jobs:
- job: unitTests
displayName: 'Base build and unit tests'
steps:
- task: NodeTool@0
inputs:
versionSpec: '10.x'
displayName: 'Install Node.js'
- script: |
./scripts/check-package-names.sh
displayName: 'check package names'
- script: |
npm install
npm run bootstrap
displayName: 'npm install, bootstrap'
- script: |
./packages/caliper-publish/publish.js version check
displayName: 'version check'
- script: |
npm test
displayName: 'unit test'
- stage: IntegrationTests
displayName: Run integration tests
dependsOn: UnitTests
jobs:
- job: fabricIntegration
displayName: 'Fabric Integration Test'
variables: { BENCHMARK: fabric }
steps:
- task: NodeTool@0
inputs:
versionSpec: '10.x'
displayName: 'Install Node.js'
- script: |
.build/benchmark-integration-test-direct.sh
- job: ethereumIntegration
displayName: 'Ethereum Integration Test'
variables: { BENCHMARK: ethereum }
steps:
- task: NodeTool@0
inputs:
versionSpec: '10.x'
displayName: 'Install Node.js'
- script: |
.build/benchmark-integration-test-direct.sh
- job: besuIntegration
displayName: 'Besu Integration Test'
variables: { BENCHMARK: besu }
steps:
- task: NodeTool@0
inputs:
versionSpec: '10.x'
displayName: 'Install Node.js'
- script: |
.build/benchmark-integration-test-direct.sh
- job: fiscoIntegration
displayName: 'FISCO BCOS Integration Test'
variables: { BENCHMARK: fisco-bcos }
steps:
- task: NodeTool@0
inputs:
versionSpec: '10.x'
displayName: 'Install Node.js'
- script: |
.build/benchmark-integration-test-direct.sh
- job: generatorIntegration
displayName: 'Generator Integration Test'
variables: { BENCHMARK: generator }
steps:
- task: NodeTool@0
inputs:
versionSpec: '10.x'
displayName: 'Install Node.js'
- script: |
.build/benchmark-integration-test-direct.sh
- stage: Publish
displayName: Publish Caliper
condition: and(succeeded(), eq(variables['Build.SourceBranch'], 'refs/heads/master'), eq(variables['Build.Reason'], 'IndividualCI'))
jobs:
- job: PublishNPM
displayName: 'Publish Caliper NPM packages'
steps:
- task: NodeTool@0
inputs:
versionSpec: '10.x'
displayName: 'Install Node.js'
- script: .build/publish-npm.sh
displayName: Publish packages
env:
NPM_TOKEN: "$(npm)"