]> source.dussan.org Git - sonarqube.git/blob
762028e42a472d23489fca28cc726cf1768c4471
[sonarqube.git] /
1 // Jest Snapshot v1, https://goo.gl/fbAQLP
2
3 exports[`should render correctly for a file 1`] = `
4 <div
5   className="layout-page-main no-outline"
6 >
7   <A11ySkipTarget
8     anchor="measures_main"
9   />
10   <div
11     className="layout-page-header-panel layout-page-main-header"
12   >
13     <div
14       className="layout-page-header-panel-inner layout-page-main-header-inner"
15     >
16       <div
17         className="layout-page-main-inner"
18       >
19         <MeasureContentHeader
20           left={
21             <Breadcrumbs
22               backToFirst={true}
23               className="text-ellipsis flex-1"
24               component={
25                 Object {
26                   "key": "foo:src/index.tsx",
27                   "measures": Array [
28                     Object {
29                       "bestValue": false,
30                       "metric": "bugs",
31                       "value": "1",
32                     },
33                   ],
34                   "name": "index.tsx",
35                   "path": "src/index.tsx",
36                   "qualifier": "FIL",
37                 }
38               }
39               handleSelect={[Function]}
40               rootComponent={
41                 Object {
42                   "key": "foo",
43                   "measures": Array [
44                     Object {
45                       "bestValue": false,
46                       "metric": "bugs",
47                       "value": "12",
48                     },
49                   ],
50                   "name": "Foo",
51                   "qualifier": "TRK",
52                 }
53               }
54             />
55           }
56           right={
57             <div
58               className="display-flex-center"
59             />
60           }
61         />
62       </div>
63     </div>
64   </div>
65   <div
66     className="layout-page-main-inner measure-details-content"
67   >
68     <MeasureHeader
69       component={
70         Object {
71           "key": "foo:src/index.tsx",
72           "measures": Array [
73             Object {
74               "bestValue": false,
75               "metric": "bugs",
76               "value": "1",
77             },
78           ],
79           "name": "index.tsx",
80           "path": "src/index.tsx",
81           "qualifier": "FIL",
82         }
83       }
84       measureValue="12"
85       metric={
86         Object {
87           "domain": "Reliability",
88           "id": "1",
89           "key": "bugs",
90           "name": "Bugs",
91           "type": "INT",
92         }
93       }
94     />
95     <div
96       className="measure-details-viewer"
97     >
98       <SourceViewer
99         component="foo:src/index.tsx"
100       />
101     </div>
102   </div>
103 </div>
104 `;
105
106 exports[`should render correctly for a project 1`] = `
107 <div
108   className="layout-page-main no-outline"
109 >
110   <A11ySkipTarget
111     anchor="measures_main"
112   />
113   <div
114     className="layout-page-header-panel layout-page-main-header"
115   >
116     <div
117       className="layout-page-header-panel-inner layout-page-main-header-inner"
118     >
119       <div
120         className="layout-page-main-inner"
121       >
122         <MeasureContentHeader
123           left={
124             <Breadcrumbs
125               backToFirst={true}
126               className="text-ellipsis flex-1"
127               component={
128                 Object {
129                   "key": "foo",
130                   "measures": Array [
131                     Object {
132                       "bestValue": false,
133                       "metric": "bugs",
134                       "value": "12",
135                     },
136                   ],
137                   "name": "Foo",
138                   "qualifier": "TRK",
139                 }
140               }
141               handleSelect={[Function]}
142               rootComponent={
143                 Object {
144                   "key": "foo",
145                   "measures": Array [
146                     Object {
147                       "bestValue": false,
148                       "metric": "bugs",
149                       "value": "12",
150                     },
151                   ],
152                   "name": "Foo",
153                   "qualifier": "TRK",
154                 }
155               }
156             />
157           }
158           right={
159             <div
160               className="display-flex-center"
161             >
162               <React.Fragment>
163                 <div>
164                   component_measures.view_as
165                 </div>
166                 <MeasureViewSelect
167                   className="measure-view-select spacer-left big-spacer-right"
168                   handleViewChange={[Function]}
169                   metric={
170                     Object {
171                       "bestValue": "0",
172                       "custom": false,
173                       "description": "Bugs",
174                       "domain": "Reliability",
175                       "hidden": false,
176                       "higherValuesAreBetter": false,
177                       "key": "bugs",
178                       "name": "Bugs",
179                       "qualitative": true,
180                       "type": "INT",
181                     }
182                   }
183                   view="list"
184                 />
185                 <PageActions
186                   showShortcuts={true}
187                   total={2}
188                 />
189               </React.Fragment>
190             </div>
191           }
192         />
193       </div>
194     </div>
195   </div>
196   <div
197     className="layout-page-main-inner measure-details-content"
198   >
199     <MeasureHeader
200       component={
201         Object {
202           "key": "foo",
203           "measures": Array [
204             Object {
205               "bestValue": false,
206               "metric": "bugs",
207               "value": "12",
208             },
209           ],
210           "name": "Foo",
211           "qualifier": "TRK",
212         }
213       }
214       measureValue="12"
215       metric={
216         Object {
217           "bestValue": "0",
218           "custom": false,
219           "description": "Bugs",
220           "domain": "Reliability",
221           "hidden": false,
222           "higherValuesAreBetter": false,
223           "key": "bugs",
224           "name": "Bugs",
225           "qualitative": true,
226           "type": "INT",
227         }
228       }
229     />
230     <FilesView
231       components={
232         Array [
233           Object {
234             "key": "foo:src/index.tsx",
235             "leak": undefined,
236             "measures": Array [
237               Object {
238                 "bestValue": false,
239                 "leak": undefined,
240                 "metric": Object {
241                   "domain": "Reliability",
242                   "id": "1",
243                   "key": "bugs",
244                   "name": "Bugs",
245                   "type": "INT",
246                 },
247                 "value": "1",
248               },
249             ],
250             "name": "index.tsx",
251             "path": "src/index.tsx",
252             "qualifier": "FIL",
253             "value": "1",
254           },
255         ]
256       }
257       defaultShowBestMeasures={false}
258       fetchMore={[Function]}
259       handleOpen={[Function]}
260       handleSelect={[Function]}
261       loadingMore={false}
262       metric={
263         Object {
264           "bestValue": "0",
265           "custom": false,
266           "description": "Bugs",
267           "domain": "Reliability",
268           "hidden": false,
269           "higherValuesAreBetter": false,
270           "key": "bugs",
271           "name": "Bugs",
272           "qualitative": true,
273           "type": "INT",
274         }
275       }
276       metrics={
277         Object {
278           "bugs": Object {
279             "domain": "Reliability",
280             "id": "1",
281             "key": "bugs",
282             "name": "Bugs",
283             "type": "INT",
284           },
285         }
286       }
287       paging={
288         Object {
289           "pageIndex": 1,
290           "pageSize": 500,
291           "total": 2,
292         }
293       }
294       rootComponent={
295         Object {
296           "key": "foo",
297           "measures": Array [
298             Object {
299               "bestValue": false,
300               "metric": "bugs",
301               "value": "12",
302             },
303           ],
304           "name": "Foo",
305           "qualifier": "TRK",
306         }
307       }
308       view="list"
309     />
310   </div>
311 </div>
312 `;