]> source.dussan.org Git - sonarqube.git/blob
485d34fdda9dfdc964c30485535745b5b119d149
[sonarqube.git] /
1 // Jest Snapshot v1, https://goo.gl/fbAQLP
2
3 exports[`should render correctly for 1`] = `
4 <Fragment>
5   <DefaultProjectKey
6     component={
7       {
8         "breadcrumbs": [],
9         "key": "my-project",
10         "name": "MyProject",
11         "qualifier": "TRK",
12         "qualityGate": {
13           "isDefault": true,
14           "key": "30",
15           "name": "Sonar way",
16         },
17         "qualityProfiles": [
18           {
19             "deleted": false,
20             "key": "my-qp",
21             "language": "ts",
22             "name": "Sonar way",
23           },
24         ],
25         "tags": [],
26       }
27     }
28   />
29   <li
30     className="abs-width-600"
31   >
32     onboarding.build.other.os
33     <RenderOptions
34       label="onboarding.build.other.os"
35       onCheck={[Function]}
36       optionLabelKey="onboarding.build.other.os"
37       options={
38         [
39           "linux",
40           "win",
41           "mac",
42         ]
43       }
44     />
45   </li>
46 </Fragment>
47 `;
48
49 exports[`should render correctly for linux: linux 1`] = `
50 <Fragment>
51   <DefaultProjectKey
52     component={
53       {
54         "breadcrumbs": [],
55         "key": "my-project",
56         "name": "MyProject",
57         "qualifier": "TRK",
58         "qualityGate": {
59           "isDefault": true,
60           "key": "30",
61           "name": "Sonar way",
62         },
63         "qualityProfiles": [
64           {
65             "deleted": false,
66             "key": "my-qp",
67             "language": "ts",
68             "name": "Sonar way",
69           },
70         ],
71         "tags": [],
72       }
73     }
74   />
75   <li
76     className="abs-width-600"
77   >
78     onboarding.build.other.os
79     <RenderOptions
80       checked="linux"
81       label="onboarding.build.other.os"
82       onCheck={[Function]}
83       optionLabelKey="onboarding.build.other.os"
84       options={
85         [
86           "linux",
87           "win",
88           "mac",
89         ]
90       }
91     />
92     <GithubCFamilyExampleRepositories
93       ci="jenkins"
94       className="big-spacer-top big-spacer-bottom"
95       os="linux"
96     />
97   </li>
98   <CreateJenkinsfileBulletPoint
99     alertTranslationKeyPart="onboarding.tutorial.with.jenkins.jenkinsfile.other.step3"
100     snippet="node {
101   stage('SCM') {
102     checkout scm
103   }
104   stage('Download Build Wrapper') {
105     sh "mkdir -p .sonar"
106     sh "curl -sSLo build-wrapper-linux-x86.zip nice_url_sample/static/cpp/build-wrapper-linux-x86.zip"
107     sh "unzip -o build-wrapper-linux-x86.zip -d .sonar"
108   }
109   stage('Build') {
110     sh ".sonar/build-wrapper-linux-x86/build-wrapper-linux-x86-64 --out-dir bw-output <your clean build command>"
111   }
112   stage('SonarQube Analysis') {
113     def scannerHome = tool 'SonarScanner';
114     withSonarQubeEnv() {
115       sh "\${scannerHome}/bin/sonar-scanner -Dsonar.cfamily.build-wrapper-output=bw-output"
116     }
117   }
118 }"
119   >
120     <CompilationInfo />
121   </CreateJenkinsfileBulletPoint>
122   <FinishButton
123     onClick={[MockFunction]}
124   />
125 </Fragment>
126 `;
127
128 exports[`should render correctly for mac: mac 1`] = `
129 <Fragment>
130   <DefaultProjectKey
131     component={
132       {
133         "breadcrumbs": [],
134         "key": "my-project",
135         "name": "MyProject",
136         "qualifier": "TRK",
137         "qualityGate": {
138           "isDefault": true,
139           "key": "30",
140           "name": "Sonar way",
141         },
142         "qualityProfiles": [
143           {
144             "deleted": false,
145             "key": "my-qp",
146             "language": "ts",
147             "name": "Sonar way",
148           },
149         ],
150         "tags": [],
151       }
152     }
153   />
154   <li
155     className="abs-width-600"
156   >
157     onboarding.build.other.os
158     <RenderOptions
159       checked="mac"
160       label="onboarding.build.other.os"
161       onCheck={[Function]}
162       optionLabelKey="onboarding.build.other.os"
163       options={
164         [
165           "linux",
166           "win",
167           "mac",
168         ]
169       }
170     />
171     <GithubCFamilyExampleRepositories
172       ci="jenkins"
173       className="big-spacer-top big-spacer-bottom"
174       os="mac"
175     />
176   </li>
177   <CreateJenkinsfileBulletPoint
178     alertTranslationKeyPart="onboarding.tutorial.with.jenkins.jenkinsfile.other.step3"
179     snippet="node {
180   stage('SCM') {
181     checkout scm
182   }
183   stage('Download Build Wrapper') {
184     sh '''
185       mkdir -p .sonar
186       curl -sSLo build-wrapper-macosx-x86.zip nice_url_sample/static/cpp/build-wrapper-macosx-x86.zip
187       unzip -o build-wrapper-macosx-x86.zip -d .sonar
188     '''
189   }
190   stage('Build') {
191     sh '''
192       .sonar/build-wrapper-macosx-x86/build-wrapper-macosx-x86 --out-dir bw-output <your clean build command>
193     '''
194   }
195   stage('SonarQube Analysis') {
196     def scannerHome = tool 'SonarScanner';
197     withSonarQubeEnv() {
198       sh "\${scannerHome}/bin/sonar-scanner -Dsonar.cfamily.build-wrapper-output=bw-output"
199     }
200   }
201 }"
202   >
203     <CompilationInfo />
204   </CreateJenkinsfileBulletPoint>
205   <FinishButton
206     onClick={[MockFunction]}
207   />
208 </Fragment>
209 `;
210
211 exports[`should render correctly for win: win 1`] = `
212 <Fragment>
213   <DefaultProjectKey
214     component={
215       {
216         "breadcrumbs": [],
217         "key": "my-project",
218         "name": "MyProject",
219         "qualifier": "TRK",
220         "qualityGate": {
221           "isDefault": true,
222           "key": "30",
223           "name": "Sonar way",
224         },
225         "qualityProfiles": [
226           {
227             "deleted": false,
228             "key": "my-qp",
229             "language": "ts",
230             "name": "Sonar way",
231           },
232         ],
233         "tags": [],
234       }
235     }
236   />
237   <li
238     className="abs-width-600"
239   >
240     onboarding.build.other.os
241     <RenderOptions
242       checked="win"
243       label="onboarding.build.other.os"
244       onCheck={[Function]}
245       optionLabelKey="onboarding.build.other.os"
246       options={
247         [
248           "linux",
249           "win",
250           "mac",
251         ]
252       }
253     />
254     <GithubCFamilyExampleRepositories
255       ci="jenkins"
256       className="big-spacer-top big-spacer-bottom"
257       os="win"
258     />
259   </li>
260   <CreateJenkinsfileBulletPoint
261     alertTranslationKeyPart="onboarding.tutorial.with.jenkins.jenkinsfile.other.step3"
262     snippet="node {
263   stage('SCM') {
264     checkout scm
265   }
266   stage('Download Build Wrapper') {
267     powershell '''
268       $path = "$HOME/.sonar/build-wrapper-win-x86.zip"
269       rm build-wrapper-win-x86 -Recurse -Force -ErrorAction SilentlyContinue
270       rm $path -Force -ErrorAction SilentlyContinue
271       mkdir $HOME/.sonar
272       [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
273       (New-Object System.Net.WebClient).DownloadFile(nice_url_sample/static/cpp/build-wrapper-win-x86.zip", $path)
274       Add-Type -AssemblyName System.IO.Compression.FileSystem
275       [System.IO.Compression.ZipFile]::ExtractToDirectory($path, "$HOME/.sonar")
276     '''
277   }
278   stage('Build') {
279     powershell '''
280       $env:Path += ";$HOME/.sonar/build-wrapper-win-x86"
281       build-wrapper-win-x86-64 --out-dir bw-output <your clean build command>
282     '''
283   }
284   stage('SonarQube Analysis') {
285     def scannerHome = tool 'SonarScanner';
286     withSonarQubeEnv() {
287       powershell "\${scannerHome}/bin/sonar-scanner -Dsonar.cfamily.build-wrapper-output=bw-output"
288     }
289   }
290 }"
291   >
292     <CompilationInfo />
293   </CreateJenkinsfileBulletPoint>
294   <FinishButton
295     onClick={[MockFunction]}
296   />
297 </Fragment>
298 `;