]> source.dussan.org Git - sonarqube.git/blob
170556dc4d097351daaca9904817f2bf0eba80ef
[sonarqube.git] /
1 // Jest Snapshot v1, https://goo.gl/fbAQLP
2
3 exports[`should render correctly: default 1`] = `
4 <div>
5   <div
6     className="layout-page-header-panel layout-page-main-header"
7   >
8     <A11ySkipTarget
9       anchor="measures_main"
10     />
11     <div
12       className="layout-page-header-panel-inner layout-page-main-header-inner"
13     >
14       <div
15         className="layout-page-main-inner"
16       >
17         <MeasureContentHeader
18           left={
19             <Breadcrumbs
20               backToFirst={true}
21               className="text-ellipsis"
22               component={
23                 Object {
24                   "key": "foo",
25                   "measures": Array [
26                     Object {
27                       "bestValue": false,
28                       "metric": "bugs",
29                       "value": "12",
30                     },
31                   ],
32                   "name": "Foo",
33                   "qualifier": "TRK",
34                 }
35               }
36               handleSelect={[MockFunction]}
37               rootComponent={
38                 Object {
39                   "key": "foo",
40                   "measures": Array [
41                     Object {
42                       "bestValue": false,
43                       "metric": "bugs",
44                       "value": "12",
45                     },
46                   ],
47                   "name": "Foo",
48                   "qualifier": "TRK",
49                 }
50               }
51             />
52           }
53           right={
54             <PageActions
55               componentQualifier="TRK"
56               current={0}
57             />
58           }
59         />
60       </div>
61     </div>
62   </div>
63   <div
64     className="layout-page-main-inner measure-details-content"
65   >
66     <div
67       className="clearfix big-spacer-bottom"
68     />
69     <DeferredSpinner
70       loading={false}
71     />
72     <BubbleChart
73       component={
74         Object {
75           "key": "foo",
76           "measures": Array [
77             Object {
78               "bestValue": false,
79               "metric": "bugs",
80               "value": "12",
81             },
82           ],
83           "name": "Foo",
84           "qualifier": "TRK",
85         }
86       }
87       components={Array []}
88       domain="Reliability"
89       metrics={
90         Object {
91           "bugs": Object {
92             "id": "bugs",
93             "key": "bugs",
94             "name": "Bugs",
95             "type": "INT",
96           },
97           "ncloc": Object {
98             "id": "ncloc",
99             "key": "ncloc",
100             "name": "Ncloc",
101             "type": "INT",
102           },
103           "reliability_rating": Object {
104             "id": "reliability_rating",
105             "key": "reliability_rating",
106             "name": "Reliability_rating",
107             "type": "DATA",
108           },
109           "reliability_remediation_effort": Object {
110             "id": "reliability_remediation_effort",
111             "key": "reliability_remediation_effort",
112             "name": "Reliability_remediation_effort",
113             "type": "INT",
114           },
115         }
116       }
117       updateSelected={[MockFunction]}
118     />
119   </div>
120 </div>
121 `;
122
123 exports[`should render correctly: has leak period 1`] = `
124 <div>
125   <div
126     className="layout-page-header-panel layout-page-main-header"
127   >
128     <A11ySkipTarget
129       anchor="measures_main"
130     />
131     <div
132       className="layout-page-header-panel-inner layout-page-main-header-inner"
133     >
134       <div
135         className="layout-page-main-inner"
136       >
137         <MeasureContentHeader
138           left={
139             <Breadcrumbs
140               backToFirst={true}
141               branchLike={
142                 Object {
143                   "analysisDate": "2018-01-01",
144                   "excludedFromPurge": true,
145                   "isMain": false,
146                   "name": "branch-6.7",
147                 }
148               }
149               className="text-ellipsis"
150               component={
151                 Object {
152                   "key": "foo",
153                   "measures": Array [
154                     Object {
155                       "bestValue": false,
156                       "metric": "bugs",
157                       "value": "12",
158                     },
159                   ],
160                   "name": "Foo",
161                   "qualifier": "TRK",
162                 }
163               }
164               handleSelect={[MockFunction]}
165               rootComponent={
166                 Object {
167                   "key": "foo",
168                   "measures": Array [
169                     Object {
170                       "bestValue": false,
171                       "metric": "bugs",
172                       "value": "12",
173                     },
174                   ],
175                   "name": "Foo",
176                   "qualifier": "TRK",
177                 }
178               }
179             />
180           }
181           right={
182             <PageActions
183               componentQualifier="TRK"
184               current={0}
185             />
186           }
187         />
188       </div>
189     </div>
190   </div>
191   <div
192     className="layout-page-main-inner measure-details-content"
193   >
194     <div
195       className="clearfix big-spacer-bottom"
196     >
197       <InjectIntl(LeakPeriodLegend)
198         className="pull-right"
199         component={
200           Object {
201             "key": "foo",
202             "measures": Array [
203               Object {
204                 "bestValue": false,
205                 "metric": "bugs",
206                 "value": "12",
207               },
208             ],
209             "name": "Foo",
210             "qualifier": "TRK",
211           }
212         }
213         period={
214           Object {
215             "date": "2019-04-23T02:12:32+0100",
216             "index": 0,
217             "mode": "previous_version",
218           }
219         }
220       />
221     </div>
222     <DeferredSpinner
223       loading={false}
224     />
225     <BubbleChart
226       component={
227         Object {
228           "key": "foo",
229           "measures": Array [
230             Object {
231               "bestValue": false,
232               "metric": "bugs",
233               "value": "12",
234             },
235           ],
236           "name": "Foo",
237           "qualifier": "TRK",
238         }
239       }
240       components={Array []}
241       domain="Reliability"
242       metrics={
243         Object {
244           "bugs": Object {
245             "id": "bugs",
246             "key": "bugs",
247             "name": "Bugs",
248             "type": "INT",
249           },
250           "ncloc": Object {
251             "id": "ncloc",
252             "key": "ncloc",
253             "name": "Ncloc",
254             "type": "INT",
255           },
256           "reliability_rating": Object {
257             "id": "reliability_rating",
258             "key": "reliability_rating",
259             "name": "Reliability_rating",
260             "type": "DATA",
261           },
262           "reliability_remediation_effort": Object {
263             "id": "reliability_remediation_effort",
264             "key": "reliability_remediation_effort",
265             "name": "Reliability_remediation_effort",
266             "type": "INT",
267           },
268         }
269       }
270       updateSelected={[MockFunction]}
271     />
272   </div>
273 </div>
274 `;
275
276 exports[`should render correctly: is file 1`] = `
277 <div>
278   <div
279     className="layout-page-header-panel layout-page-main-header"
280   >
281     <A11ySkipTarget
282       anchor="measures_main"
283     />
284     <div
285       className="layout-page-header-panel-inner layout-page-main-header-inner"
286     >
287       <div
288         className="layout-page-main-inner"
289       >
290         <MeasureContentHeader
291           left={
292             <Breadcrumbs
293               backToFirst={true}
294               className="text-ellipsis"
295               component={
296                 Object {
297                   "key": "foo:src/index.tsx",
298                   "measures": Array [
299                     Object {
300                       "bestValue": false,
301                       "metric": "bugs",
302                       "value": "1",
303                     },
304                   ],
305                   "name": "index.tsx",
306                   "path": "src/index.tsx",
307                   "qualifier": "FIL",
308                 }
309               }
310               handleSelect={[MockFunction]}
311               rootComponent={
312                 Object {
313                   "key": "foo",
314                   "measures": Array [
315                     Object {
316                       "bestValue": false,
317                       "metric": "bugs",
318                       "value": "12",
319                     },
320                   ],
321                   "name": "Foo",
322                   "qualifier": "TRK",
323                 }
324               }
325             />
326           }
327           right={
328             <PageActions
329               componentQualifier="TRK"
330               current={0}
331             />
332           }
333         />
334       </div>
335     </div>
336   </div>
337   <div
338     className="layout-page-main-inner measure-details-content"
339   >
340     <div
341       className="clearfix big-spacer-bottom"
342     />
343     <DeferredSpinner
344       loading={false}
345     />
346     <div
347       className="measure-details-viewer"
348     >
349       <SourceViewer
350         component="foo:src/index.tsx"
351       />
352     </div>
353   </div>
354 </div>
355 `;
356
357 exports[`should render correctly: loading 1`] = `
358 <div>
359   <div
360     className="layout-page-header-panel layout-page-main-header"
361   >
362     <A11ySkipTarget
363       anchor="measures_main"
364     />
365     <div
366       className="layout-page-header-panel-inner layout-page-main-header-inner"
367     >
368       <div
369         className="layout-page-main-inner"
370       >
371         <MeasureContentHeader
372           left={
373             <Breadcrumbs
374               backToFirst={true}
375               className="text-ellipsis"
376               component={
377                 Object {
378                   "key": "foo",
379                   "measures": Array [
380                     Object {
381                       "bestValue": false,
382                       "metric": "bugs",
383                       "value": "12",
384                     },
385                   ],
386                   "name": "Foo",
387                   "qualifier": "TRK",
388                 }
389               }
390               handleSelect={[MockFunction]}
391               rootComponent={
392                 Object {
393                   "key": "foo",
394                   "measures": Array [
395                     Object {
396                       "bestValue": false,
397                       "metric": "bugs",
398                       "value": "12",
399                     },
400                   ],
401                   "name": "Foo",
402                   "qualifier": "TRK",
403                 }
404               }
405             />
406           }
407           right={
408             <PageActions
409               componentQualifier="TRK"
410               current={0}
411             />
412           }
413         />
414       </div>
415     </div>
416   </div>
417   <div
418     className="layout-page-main-inner measure-details-content"
419   >
420     <div
421       className="clearfix big-spacer-bottom"
422     />
423     <DeferredSpinner
424       loading={true}
425     />
426   </div>
427 </div>
428 `;