]> source.dussan.org Git - sonarqube.git/blob
38b723918390f844dc6354c2ad45af1a335b0655
[sonarqube.git] /
1 // Jest Snapshot v1, https://goo.gl/fbAQLP
2
3 exports[`should render maximum 10 languages in the searchbox results 1`] = `
4 <Filter
5   facet={
6     Object {
7       "cs": 4,
8       "g": 1,
9       "java": 39,
10       "js": 1,
11     }
12   }
13   footer={
14     <SearchableFilterFooter
15       isFavorite={true}
16       options={
17         Array [
18           Object {
19             "label": "Flex",
20             "value": "flex",
21           },
22           Object {
23             "label": "PHP",
24             "value": "php",
25           },
26           Object {
27             "label": "Python",
28             "value": "py",
29           },
30           Object {
31             "label": "c",
32             "value": "c",
33           },
34           Object {
35             "label": "d",
36             "value": "d",
37           },
38           Object {
39             "label": "e",
40             "value": "e",
41           },
42           Object {
43             "label": "f",
44             "value": "f",
45           },
46           Object {
47             "label": "h",
48             "value": "h",
49           },
50           Object {
51             "label": "i",
52             "value": "i",
53           },
54           Object {
55             "label": "k",
56             "value": "k",
57           },
58         ]
59       }
60       property="languages"
61       query={
62         Object {
63           "languages": Array [
64             "java",
65             "g",
66           ],
67         }
68       }
69     />
70   }
71   getFacetValueForOption={[Function]}
72   header={
73     <FilterHeader
74       name="projects.facets.languages"
75     />
76   }
77   isFavorite={true}
78   options={
79     Array [
80       "java",
81       "cs",
82       "g",
83       "js",
84     ]
85   }
86   property="languages"
87   query={
88     Object {
89       "languages": Array [
90         "java",
91         "g",
92       ],
93     }
94   }
95   renderOption={[Function]}
96   value={
97     Array [
98       "java",
99       "g",
100     ]
101   }
102 />
103 `;
104
105 exports[`should render the languages facet with the selected languages 1`] = `
106 <Filter
107   facet={
108     Object {
109       "cs": 4,
110       "java": 39,
111       "js": 1,
112     }
113   }
114   footer={
115     <SearchableFilterFooter
116       isFavorite={true}
117       options={
118         Array [
119           Object {
120             "label": "Flex",
121             "value": "flex",
122           },
123           Object {
124             "label": "PHP",
125             "value": "php",
126           },
127           Object {
128             "label": "Python",
129             "value": "py",
130           },
131         ]
132       }
133       property="languages"
134       query={
135         Object {
136           "languages": Array [
137             "java",
138             "cs",
139           ],
140         }
141       }
142     />
143   }
144   getFacetValueForOption={[Function]}
145   header={
146     <FilterHeader
147       name="projects.facets.languages"
148     />
149   }
150   isFavorite={true}
151   options={
152     Array [
153       "java",
154       "cs",
155       "js",
156     ]
157   }
158   property="languages"
159   query={
160     Object {
161       "languages": Array [
162         "java",
163         "cs",
164       ],
165     }
166   }
167   renderOption={[Function]}
168   value={
169     Array [
170       "java",
171       "cs",
172     ]
173   }
174 />
175 `;
176
177 exports[`should render the languages facet with the selected languages 2`] = `
178 <div
179   className="search-navigator-facet-box"
180   data-key="languages"
181 >
182   <FilterHeader
183     name="projects.facets.languages"
184   />
185   <div
186     className="search-navigator-facet-list projects-facet-list"
187   >
188     <Link
189       className="facet search-navigator-facet projects-facet active"
190       data-key="java"
191       onClick={[Function]}
192       onlyActiveOnIndex={false}
193       style={Object {}}
194       to={
195         Object {
196           "pathname": "/projects/favorite",
197           "query": Object {
198             "languages": "cs",
199           },
200         }
201       }
202     >
203       <span
204         className="facet-name"
205       >
206         <SearchableFilterOption
207           option={
208             Object {
209               "key": "java",
210               "name": "Java",
211             }
212           }
213           optionKey="java"
214         />
215       </span>
216       <span
217         className="facet-stat"
218       >
219         39
220       </span>
221     </Link>
222     <Link
223       className="facet search-navigator-facet projects-facet active"
224       data-key="cs"
225       onClick={[Function]}
226       onlyActiveOnIndex={false}
227       style={Object {}}
228       to={
229         Object {
230           "pathname": "/projects/favorite",
231           "query": Object {
232             "languages": "java",
233           },
234         }
235       }
236     >
237       <span
238         className="facet-name"
239       >
240         <SearchableFilterOption
241           option={
242             Object {
243               "key": "cs",
244               "name": "C#",
245             }
246           }
247           optionKey="cs"
248         />
249       </span>
250       <span
251         className="facet-stat"
252       >
253         4
254       </span>
255     </Link>
256     <Link
257       className="facet search-navigator-facet projects-facet"
258       data-key="js"
259       onClick={[Function]}
260       onlyActiveOnIndex={false}
261       style={Object {}}
262       to={
263         Object {
264           "pathname": "/projects/favorite",
265           "query": Object {
266             "languages": "java,cs,js",
267           },
268         }
269       }
270     >
271       <span
272         className="facet-name"
273       >
274         <SearchableFilterOption
275           option={
276             Object {
277               "key": "js",
278               "name": "JavaScript",
279             }
280           }
281           optionKey="js"
282         />
283       </span>
284       <span
285         className="facet-stat"
286       >
287         1
288       </span>
289     </Link>
290   </div>
291   <SearchableFilterFooter
292     isFavorite={true}
293     options={
294       Array [
295         Object {
296           "label": "Flex",
297           "value": "flex",
298         },
299         Object {
300           "label": "PHP",
301           "value": "php",
302         },
303         Object {
304           "label": "Python",
305           "value": "py",
306         },
307       ]
308     }
309     property="languages"
310     query={
311       Object {
312         "languages": Array [
313           "java",
314           "cs",
315         ],
316       }
317     }
318   />
319 </div>
320 `;
321
322 exports[`should render the languages without the ones in the facet 1`] = `
323 <Filter
324   facet={
325     Object {
326       "cs": 4,
327       "java": 39,
328       "js": 1,
329     }
330   }
331   footer={
332     <SearchableFilterFooter
333       options={
334         Array [
335           Object {
336             "label": "Flex",
337             "value": "flex",
338           },
339           Object {
340             "label": "PHP",
341             "value": "php",
342           },
343           Object {
344             "label": "Python",
345             "value": "py",
346           },
347         ]
348       }
349       property="languages"
350       query={
351         Object {
352           "languages": null,
353         }
354       }
355     />
356   }
357   getFacetValueForOption={[Function]}
358   header={
359     <FilterHeader
360       name="projects.facets.languages"
361     />
362   }
363   options={
364     Array [
365       "java",
366       "cs",
367       "js",
368     ]
369   }
370   property="languages"
371   query={
372     Object {
373       "languages": null,
374     }
375   }
376   renderOption={[Function]}
377 />
378 `;