]> source.dussan.org Git - sonarqube.git/blob
6b09bf1ea0be071473ff36ab79efde28ad4fd055
[sonarqube.git] /
1 // Jest Snapshot v1, https://goo.gl/fbAQLP
2
3 exports[`should render source file 1`] = `
4 <Modal
5   contentLabel="component_viewer.file_measures"
6   onRequestClose={[MockFunction]}
7   size="large"
8 >
9   <div
10     className="modal-head"
11   >
12     <h2>
13       component_viewer.file_measures
14     </h2>
15   </div>
16   <div
17     className="modal-body modal-container"
18   >
19     <div
20       className="measures-viewer-header big-spacer-bottom"
21     >
22       <div>
23         <QualifierIcon
24           className="little-spacer-right"
25           qualifier="TRK"
26         />
27         <Link
28           to={
29             Object {
30               "pathname": "/dashboard",
31               "search": "?branch=feature&id=project-key",
32             }
33           }
34         >
35           Project Name
36         </Link>
37       </div>
38       <div
39         className="display-flex-center little-spacer-top"
40       >
41         <QualifierIcon
42           className="little-spacer-right"
43           qualifier="FIL"
44         />
45         src/file.js
46       </div>
47     </div>
48     <div
49       className="measures-viewer"
50     >
51       <div
52         className="measures-viewer-section"
53       >
54         <div
55           className="measures-viewer-card"
56         >
57           <div
58             className="measures"
59           >
60             <MeasuresOverlayMeasure
61               key="lines"
62               measure={
63                 Object {
64                   "metric": Object {
65                     "domain": "Size",
66                     "key": "lines",
67                     "type": "INT",
68                   },
69                   "value": "18",
70                 }
71               }
72             />
73             <MeasuresOverlayMeasure
74               key="ncloc"
75               measure={
76                 Object {
77                   "metric": Object {
78                     "domain": "Size",
79                     "key": "ncloc",
80                     "type": "INT",
81                   },
82                   "value": "8",
83                 }
84               }
85             />
86             <MeasuresOverlayMeasure
87               key="comment_lines"
88               measure={
89                 Object {
90                   "metric": Object {
91                     "domain": "Size",
92                     "key": "comment_lines",
93                     "type": "INT",
94                   },
95                   "value": "2",
96                 }
97               }
98             />
99             <MeasuresOverlayMeasure
100               key="comment_lines_density"
101               measure={
102                 Object {
103                   "metric": Object {
104                     "domain": "Size",
105                     "key": "comment_lines_density",
106                     "type": "PERCENT",
107                   },
108                   "value": "20.0",
109                 }
110               }
111             />
112           </div>
113           <div
114             className="measures"
115           >
116             <MeasuresOverlayMeasure
117               key="cognitive_complexity"
118               measure={
119                 Object {
120                   "metric": Object {
121                     "domain": "Complexity",
122                     "key": "cognitive_complexity",
123                     "type": "INT",
124                   },
125                   "value": "0",
126                 }
127               }
128             />
129             <MeasuresOverlayMeasure
130               key="complexity"
131               measure={
132                 Object {
133                   "metric": Object {
134                     "domain": "Complexity",
135                     "key": "complexity",
136                     "type": "INT",
137                   },
138                   "value": "1",
139                 }
140               }
141             />
142           </div>
143         </div>
144       </div>
145       <div
146         className="measures-viewer-section"
147       >
148         <div
149           className="measures-viewer-card"
150         >
151           <div
152             className="measures"
153           >
154             <div
155               className="measure measure-big"
156               data-metric="violations"
157             >
158               <span
159                 className="measure-value"
160               >
161                 <Measure
162                   metricKey="violations"
163                   metricType="INT"
164                   value="1"
165                 />
166               </span>
167               <span
168                 className="measure-name"
169               >
170                 violations
171               </span>
172             </div>
173             <div
174               className="measure measure-big"
175               data-metric="sqale_index"
176             >
177               <span
178                 className="measure-value"
179               >
180                 <Measure
181                   metricKey="sqale_index"
182                   metricType="WORK_DUR"
183                   value="40"
184                 />
185               </span>
186               <span
187                 className="measure-name"
188               >
189                 sqale_index
190               </span>
191             </div>
192           </div>
193           <div
194             className="measures"
195           >
196             <div
197               className="measure measure-one-line"
198               key="BUG"
199             >
200               <span
201                 className="measure-name"
202               >
203                 <IssueTypeIcon
204                   className="little-spacer-right"
205                   query="BUG"
206                 />
207                 issue.type.BUG
208               </span>
209               <span
210                 className="measure-value"
211               >
212                 1
213               </span>
214             </div>
215             <div
216               className="measure measure-one-line"
217               key="VULNERABILITY"
218             >
219               <span
220                 className="measure-name"
221               >
222                 <IssueTypeIcon
223                   className="little-spacer-right"
224                   query="VULNERABILITY"
225                 />
226                 issue.type.VULNERABILITY
227               </span>
228               <span
229                 className="measure-value"
230               >
231                 0
232               </span>
233             </div>
234             <div
235               className="measure measure-one-line"
236               key="CODE_SMELL"
237             >
238               <span
239                 className="measure-name"
240               >
241                 <IssueTypeIcon
242                   className="little-spacer-right"
243                   query="CODE_SMELL"
244                 />
245                 issue.type.CODE_SMELL
246               </span>
247               <span
248                 className="measure-value"
249               >
250                 2
251               </span>
252             </div>
253           </div>
254           <div
255             className="measures"
256           >
257             <div
258               className="measure measure-one-line"
259               key="BLOCKER"
260             >
261               <span
262                 className="measure-name"
263               >
264                 <SeverityHelper
265                   severity="BLOCKER"
266                 />
267               </span>
268               <span
269                 className="measure-value"
270               >
271                 5
272               </span>
273             </div>
274             <div
275               className="measure measure-one-line"
276               key="CRITICAL"
277             >
278               <span
279                 className="measure-name"
280               >
281                 <SeverityHelper
282                   severity="CRITICAL"
283                 />
284               </span>
285               <span
286                 className="measure-value"
287               >
288                 4
289               </span>
290             </div>
291             <div
292               className="measure measure-one-line"
293               key="MAJOR"
294             >
295               <span
296                 className="measure-name"
297               >
298                 <SeverityHelper
299                   severity="MAJOR"
300                 />
301               </span>
302               <span
303                 className="measure-value"
304               >
305                 1
306               </span>
307             </div>
308             <div
309               className="measure measure-one-line"
310               key="MINOR"
311             >
312               <span
313                 className="measure-name"
314               >
315                 <SeverityHelper
316                   severity="MINOR"
317                 />
318               </span>
319               <span
320                 className="measure-value"
321               >
322                 3
323               </span>
324             </div>
325             <div
326               className="measure measure-one-line"
327               key="INFO"
328             >
329               <span
330                 className="measure-name"
331               >
332                 <SeverityHelper
333                   severity="INFO"
334                 />
335               </span>
336               <span
337                 className="measure-value"
338               >
339                 2
340               </span>
341             </div>
342           </div>
343           <div
344             className="measures"
345           >
346             <div
347               className="measure measure-one-line"
348               key="bad-practice"
349             >
350               <span
351                 className="measure-name"
352               >
353                 <TagsIcon
354                   className="little-spacer-right"
355                 />
356                 bad-practice
357               </span>
358               <span
359                 className="measure-value"
360               >
361                 1
362               </span>
363             </div>
364             <div
365               className="measure measure-one-line"
366               key="cert"
367             >
368               <span
369                 className="measure-name"
370               >
371                 <TagsIcon
372                   className="little-spacer-right"
373                 />
374                 cert
375               </span>
376               <span
377                 className="measure-value"
378               >
379                 3
380               </span>
381             </div>
382             <div
383               className="measure measure-one-line"
384               key="design"
385             >
386               <span
387                 className="measure-name"
388               >
389                 <TagsIcon
390                   className="little-spacer-right"
391                 />
392                 design
393               </span>
394               <span
395                 className="measure-value"
396               >
397                 1
398               </span>
399             </div>
400           </div>
401         </div>
402       </div>
403       <div
404         className="measures-viewer-section"
405       >
406         <div
407           className="measures-viewer-card"
408         >
409           <div
410             className="measures"
411           >
412             <div
413               className="measures-chart"
414             >
415               <CoverageRating
416                 size="big"
417                 value="75.0"
418               />
419             </div>
420             <div
421               className="measure measure-big"
422               data-metric="coverage"
423             >
424               <span
425                 className="measure-value"
426               >
427                 <Measure
428                   metricKey="coverage"
429                   metricType="PERCENT"
430                   value="75.0"
431                 />
432               </span>
433               <span
434                 className="measure-name"
435               >
436                 coverage
437               </span>
438             </div>
439           </div>
440           <div
441             className="measures"
442           >
443             <MeasuresOverlayMeasure
444               key="uncovered_lines"
445               measure={
446                 Object {
447                   "metric": Object {
448                     "domain": "Coverage",
449                     "key": "uncovered_lines",
450                     "type": "INT",
451                   },
452                   "value": "1",
453                 }
454               }
455             />
456             <MeasuresOverlayMeasure
457               key="lines_to_cover"
458               measure={
459                 Object {
460                   "metric": Object {
461                     "domain": "Coverage",
462                     "key": "lines_to_cover",
463                     "type": "INT",
464                   },
465                   "value": "4",
466                 }
467               }
468             />
469           </div>
470         </div>
471       </div>
472       <div
473         className="measures-viewer-section"
474       >
475         <div
476           className="measures-viewer-card"
477         >
478           <div
479             className="measures"
480           >
481             <div
482               className="measures-chart"
483             >
484               <DuplicationsRating
485                 muted={false}
486                 size="big"
487                 value={0}
488               />
489             </div>
490             <div
491               className="measure measure-big"
492               data-metric="duplicated_lines_density"
493             >
494               <span
495                 className="measure-value"
496               >
497                 <Measure
498                   metricKey="duplicated_lines_density"
499                   metricType="PERCENT"
500                   value="0.0"
501                 />
502               </span>
503               <span
504                 className="measure-name"
505               >
506                 duplicated_lines_density
507               </span>
508             </div>
509           </div>
510           <div
511             className="measures"
512           >
513             <MeasuresOverlayMeasure
514               key="duplicated_blocks"
515               measure={
516                 Object {
517                   "metric": Object {
518                     "domain": "Duplications",
519                     "key": "duplicated_blocks",
520                     "type": "INT",
521                   },
522                   "value": "3",
523                 }
524               }
525             />
526             <MeasuresOverlayMeasure
527               key="duplicated_lines"
528               measure={
529                 Object {
530                   "metric": Object {
531                     "domain": "Duplications",
532                     "key": "duplicated_lines",
533                     "type": "INT",
534                   },
535                   "value": "0",
536                 }
537               }
538             />
539           </div>
540         </div>
541       </div>
542     </div>
543     <div
544       className="spacer-top"
545     >
546       <a
547         className="js-show-all-measures"
548         href="#"
549         onClick={[Function]}
550       >
551         component_viewer.show_all_measures
552       </a>
553     </div>
554   </div>
555   <footer
556     className="modal-foot"
557   >
558     <ResetButtonLink
559       onClick={[MockFunction]}
560     >
561       close
562     </ResetButtonLink>
563   </footer>
564 </Modal>
565 `;
566
567 exports[`should render source file 2`] = `
568 <Modal
569   contentLabel="component_viewer.file_measures"
570   onRequestClose={[MockFunction]}
571   size="large"
572 >
573   <div
574     className="modal-head"
575   >
576     <h2>
577       component_viewer.file_measures
578     </h2>
579   </div>
580   <div
581     className="modal-body modal-container"
582   >
583     <div
584       className="measures-viewer-header big-spacer-bottom"
585     >
586       <div>
587         <QualifierIcon
588           className="little-spacer-right"
589           qualifier="TRK"
590         />
591         <Link
592           to={
593             Object {
594               "pathname": "/dashboard",
595               "search": "?branch=feature&id=project-key",
596             }
597           }
598         >
599           Project Name
600         </Link>
601       </div>
602       <div
603         className="display-flex-center little-spacer-top"
604       >
605         <QualifierIcon
606           className="little-spacer-right"
607           qualifier="FIL"
608         />
609         src/file.js
610       </div>
611     </div>
612     <div
613       className="measures-viewer"
614     >
615       <div
616         className="measures-viewer-section"
617       >
618         <div
619           className="measures-viewer-card"
620         >
621           <div
622             className="measures"
623           >
624             <MeasuresOverlayMeasure
625               key="lines"
626               measure={
627                 Object {
628                   "metric": Object {
629                     "domain": "Size",
630                     "key": "lines",
631                     "type": "INT",
632                   },
633                   "value": "18",
634                 }
635               }
636             />
637             <MeasuresOverlayMeasure
638               key="ncloc"
639               measure={
640                 Object {
641                   "metric": Object {
642                     "domain": "Size",
643                     "key": "ncloc",
644                     "type": "INT",
645                   },
646                   "value": "8",
647                 }
648               }
649             />
650             <MeasuresOverlayMeasure
651               key="comment_lines"
652               measure={
653                 Object {
654                   "metric": Object {
655                     "domain": "Size",
656                     "key": "comment_lines",
657                     "type": "INT",
658                   },
659                   "value": "2",
660                 }
661               }
662             />
663             <MeasuresOverlayMeasure
664               key="comment_lines_density"
665               measure={
666                 Object {
667                   "metric": Object {
668                     "domain": "Size",
669                     "key": "comment_lines_density",
670                     "type": "PERCENT",
671                   },
672                   "value": "20.0",
673                 }
674               }
675             />
676           </div>
677           <div
678             className="measures"
679           >
680             <MeasuresOverlayMeasure
681               key="cognitive_complexity"
682               measure={
683                 Object {
684                   "metric": Object {
685                     "domain": "Complexity",
686                     "key": "cognitive_complexity",
687                     "type": "INT",
688                   },
689                   "value": "0",
690                 }
691               }
692             />
693             <MeasuresOverlayMeasure
694               key="complexity"
695               measure={
696                 Object {
697                   "metric": Object {
698                     "domain": "Complexity",
699                     "key": "complexity",
700                     "type": "INT",
701                   },
702                   "value": "1",
703                 }
704               }
705             />
706           </div>
707         </div>
708       </div>
709       <div
710         className="measures-viewer-section"
711       >
712         <div
713           className="measures-viewer-card"
714         >
715           <div
716             className="measures"
717           >
718             <div
719               className="measure measure-big"
720               data-metric="violations"
721             >
722               <span
723                 className="measure-value"
724               >
725                 <Measure
726                   metricKey="violations"
727                   metricType="INT"
728                   value="1"
729                 />
730               </span>
731               <span
732                 className="measure-name"
733               >
734                 violations
735               </span>
736             </div>
737             <div
738               className="measure measure-big"
739               data-metric="sqale_index"
740             >
741               <span
742                 className="measure-value"
743               >
744                 <Measure
745                   metricKey="sqale_index"
746                   metricType="WORK_DUR"
747                   value="40"
748                 />
749               </span>
750               <span
751                 className="measure-name"
752               >
753                 sqale_index
754               </span>
755             </div>
756           </div>
757           <div
758             className="measures"
759           >
760             <div
761               className="measure measure-one-line"
762               key="BUG"
763             >
764               <span
765                 className="measure-name"
766               >
767                 <IssueTypeIcon
768                   className="little-spacer-right"
769                   query="BUG"
770                 />
771                 issue.type.BUG
772               </span>
773               <span
774                 className="measure-value"
775               >
776                 1
777               </span>
778             </div>
779             <div
780               className="measure measure-one-line"
781               key="VULNERABILITY"
782             >
783               <span
784                 className="measure-name"
785               >
786                 <IssueTypeIcon
787                   className="little-spacer-right"
788                   query="VULNERABILITY"
789                 />
790                 issue.type.VULNERABILITY
791               </span>
792               <span
793                 className="measure-value"
794               >
795                 0
796               </span>
797             </div>
798             <div
799               className="measure measure-one-line"
800               key="CODE_SMELL"
801             >
802               <span
803                 className="measure-name"
804               >
805                 <IssueTypeIcon
806                   className="little-spacer-right"
807                   query="CODE_SMELL"
808                 />
809                 issue.type.CODE_SMELL
810               </span>
811               <span
812                 className="measure-value"
813               >
814                 2
815               </span>
816             </div>
817           </div>
818           <div
819             className="measures"
820           >
821             <div
822               className="measure measure-one-line"
823               key="BLOCKER"
824             >
825               <span
826                 className="measure-name"
827               >
828                 <SeverityHelper
829                   severity="BLOCKER"
830                 />
831               </span>
832               <span
833                 className="measure-value"
834               >
835                 5
836               </span>
837             </div>
838             <div
839               className="measure measure-one-line"
840               key="CRITICAL"
841             >
842               <span
843                 className="measure-name"
844               >
845                 <SeverityHelper
846                   severity="CRITICAL"
847                 />
848               </span>
849               <span
850                 className="measure-value"
851               >
852                 4
853               </span>
854             </div>
855             <div
856               className="measure measure-one-line"
857               key="MAJOR"
858             >
859               <span
860                 className="measure-name"
861               >
862                 <SeverityHelper
863                   severity="MAJOR"
864                 />
865               </span>
866               <span
867                 className="measure-value"
868               >
869                 1
870               </span>
871             </div>
872             <div
873               className="measure measure-one-line"
874               key="MINOR"
875             >
876               <span
877                 className="measure-name"
878               >
879                 <SeverityHelper
880                   severity="MINOR"
881                 />
882               </span>
883               <span
884                 className="measure-value"
885               >
886                 3
887               </span>
888             </div>
889             <div
890               className="measure measure-one-line"
891               key="INFO"
892             >
893               <span
894                 className="measure-name"
895               >
896                 <SeverityHelper
897                   severity="INFO"
898                 />
899               </span>
900               <span
901                 className="measure-value"
902               >
903                 2
904               </span>
905             </div>
906           </div>
907           <div
908             className="measures"
909           >
910             <div
911               className="measure measure-one-line"
912               key="bad-practice"
913             >
914               <span
915                 className="measure-name"
916               >
917                 <TagsIcon
918                   className="little-spacer-right"
919                 />
920                 bad-practice
921               </span>
922               <span
923                 className="measure-value"
924               >
925                 1
926               </span>
927             </div>
928             <div
929               className="measure measure-one-line"
930               key="cert"
931             >
932               <span
933                 className="measure-name"
934               >
935                 <TagsIcon
936                   className="little-spacer-right"
937                 />
938                 cert
939               </span>
940               <span
941                 className="measure-value"
942               >
943                 3
944               </span>
945             </div>
946             <div
947               className="measure measure-one-line"
948               key="design"
949             >
950               <span
951                 className="measure-name"
952               >
953                 <TagsIcon
954                   className="little-spacer-right"
955                 />
956                 design
957               </span>
958               <span
959                 className="measure-value"
960               >
961                 1
962               </span>
963             </div>
964           </div>
965         </div>
966       </div>
967       <div
968         className="measures-viewer-section"
969       >
970         <div
971           className="measures-viewer-card"
972         >
973           <div
974             className="measures"
975           >
976             <div
977               className="measures-chart"
978             >
979               <CoverageRating
980                 size="big"
981                 value="75.0"
982               />
983             </div>
984             <div
985               className="measure measure-big"
986               data-metric="coverage"
987             >
988               <span
989                 className="measure-value"
990               >
991                 <Measure
992                   metricKey="coverage"
993                   metricType="PERCENT"
994                   value="75.0"
995                 />
996               </span>
997               <span
998                 className="measure-name"
999               >
1000                 coverage
1001               </span>
1002             </div>
1003           </div>
1004           <div
1005             className="measures"
1006           >
1007             <MeasuresOverlayMeasure
1008               key="uncovered_lines"
1009               measure={
1010                 Object {
1011                   "metric": Object {
1012                     "domain": "Coverage",
1013                     "key": "uncovered_lines",
1014                     "type": "INT",
1015                   },
1016                   "value": "1",
1017                 }
1018               }
1019             />
1020             <MeasuresOverlayMeasure
1021               key="lines_to_cover"
1022               measure={
1023                 Object {
1024                   "metric": Object {
1025                     "domain": "Coverage",
1026                     "key": "lines_to_cover",
1027                     "type": "INT",
1028                   },
1029                   "value": "4",
1030                 }
1031               }
1032             />
1033           </div>
1034         </div>
1035       </div>
1036       <div
1037         className="measures-viewer-section"
1038       >
1039         <div
1040           className="measures-viewer-card"
1041         >
1042           <div
1043             className="measures"
1044           >
1045             <div
1046               className="measures-chart"
1047             >
1048               <DuplicationsRating
1049                 muted={false}
1050                 size="big"
1051                 value={0}
1052               />
1053             </div>
1054             <div
1055               className="measure measure-big"
1056               data-metric="duplicated_lines_density"
1057             >
1058               <span
1059                 className="measure-value"
1060               >
1061                 <Measure
1062                   metricKey="duplicated_lines_density"
1063                   metricType="PERCENT"
1064                   value="0.0"
1065                 />
1066               </span>
1067               <span
1068                 className="measure-name"
1069               >
1070                 duplicated_lines_density
1071               </span>
1072             </div>
1073           </div>
1074           <div
1075             className="measures"
1076           >
1077             <MeasuresOverlayMeasure
1078               key="duplicated_blocks"
1079               measure={
1080                 Object {
1081                   "metric": Object {
1082                     "domain": "Duplications",
1083                     "key": "duplicated_blocks",
1084                     "type": "INT",
1085                   },
1086                   "value": "3",
1087                 }
1088               }
1089             />
1090             <MeasuresOverlayMeasure
1091               key="duplicated_lines"
1092               measure={
1093                 Object {
1094                   "metric": Object {
1095                     "domain": "Duplications",
1096                     "key": "duplicated_lines",
1097                     "type": "INT",
1098                   },
1099                   "value": "0",
1100                 }
1101               }
1102             />
1103           </div>
1104         </div>
1105       </div>
1106     </div>
1107     <div
1108       className="spacer-top"
1109     >
1110       <div
1111         className="measures-viewer measures-viewer-secondary"
1112       >
1113         <div
1114           className="measures-viewer-section"
1115         >
1116           <div
1117             className="measures-viewer-card"
1118             key="Complexity"
1119           >
1120             <div
1121               className="measures"
1122             >
1123               <div
1124                 className="measure measure-big"
1125               >
1126                 <span
1127                   className="measure-name"
1128                 >
1129                   metric_domain.Complexity
1130                 </span>
1131               </div>
1132               <MeasuresOverlayMeasure
1133                 key="cognitive_complexity"
1134                 measure={
1135                   Object {
1136                     "metric": Object {
1137                       "domain": "Complexity",
1138                       "key": "cognitive_complexity",
1139                       "type": "INT",
1140                     },
1141                     "value": "0",
1142                   }
1143                 }
1144               />
1145               <MeasuresOverlayMeasure
1146                 key="complexity"
1147                 measure={
1148                   Object {
1149                     "metric": Object {
1150                       "domain": "Complexity",
1151                       "key": "complexity",
1152                       "type": "INT",
1153                     },
1154                     "value": "1",
1155                   }
1156                 }
1157               />
1158             </div>
1159           </div>
1160           <div
1161             className="measures-viewer-card"
1162             key="Size"
1163           >
1164             <div
1165               className="measures"
1166             >
1167               <div
1168                 className="measure measure-big"
1169               >
1170                 <span
1171                   className="measure-name"
1172                 >
1173                   metric_domain.Size
1174                 </span>
1175               </div>
1176               <MeasuresOverlayMeasure
1177                 key="classes"
1178                 measure={
1179                   Object {
1180                     "metric": Object {
1181                       "domain": "Size",
1182                       "key": "classes",
1183                       "type": "INT",
1184                     },
1185                     "value": "1",
1186                   }
1187                 }
1188               />
1189               <MeasuresOverlayMeasure
1190                 key="comment_lines"
1191                 measure={
1192                   Object {
1193                     "metric": Object {
1194                       "domain": "Size",
1195                       "key": "comment_lines",
1196                       "type": "INT",
1197                     },
1198                     "value": "2",
1199                   }
1200                 }
1201               />
1202               <MeasuresOverlayMeasure
1203                 key="comment_lines_density"
1204                 measure={
1205                   Object {
1206                     "metric": Object {
1207                       "domain": "Size",
1208                       "key": "comment_lines_density",
1209                       "type": "PERCENT",
1210                     },
1211                     "value": "20.0",
1212                   }
1213                 }
1214               />
1215               <MeasuresOverlayMeasure
1216                 key="files"
1217                 measure={
1218                   Object {
1219                     "metric": Object {
1220                       "domain": "Size",
1221                       "key": "files",
1222                       "type": "INT",
1223                     },
1224                     "value": "1",
1225                   }
1226                 }
1227               />
1228               <MeasuresOverlayMeasure
1229                 key="functions"
1230                 measure={
1231                   Object {
1232                     "metric": Object {
1233                       "domain": "Size",
1234                       "key": "functions",
1235                       "type": "INT",
1236                     },
1237                     "value": "1",
1238                   }
1239                 }
1240               />
1241               <MeasuresOverlayMeasure
1242                 key="lines"
1243                 measure={
1244                   Object {
1245                     "metric": Object {
1246                       "domain": "Size",
1247                       "key": "lines",
1248                       "type": "INT",
1249                     },
1250                     "value": "18",
1251                   }
1252                 }
1253               />
1254               <MeasuresOverlayMeasure
1255                 key="ncloc"
1256                 measure={
1257                   Object {
1258                     "metric": Object {
1259                       "domain": "Size",
1260                       "key": "ncloc",
1261                       "type": "INT",
1262                     },
1263                     "value": "8",
1264                   }
1265                 }
1266               />
1267               <MeasuresOverlayMeasure
1268                 key="statements"
1269                 measure={
1270                   Object {
1271                     "metric": Object {
1272                       "domain": "Size",
1273                       "key": "statements",
1274                       "type": "INT",
1275                     },
1276                     "value": "3",
1277                   }
1278                 }
1279               />
1280             </div>
1281           </div>
1282           <div
1283             className="measures-viewer-card"
1284             key="Coverage"
1285           >
1286             <div
1287               className="measures"
1288             >
1289               <div
1290                 className="measure measure-big"
1291               >
1292                 <span
1293                   className="measure-name"
1294                 >
1295                   metric_domain.Coverage
1296                 </span>
1297               </div>
1298               <MeasuresOverlayMeasure
1299                 key="coverage"
1300                 measure={
1301                   Object {
1302                     "metric": Object {
1303                       "domain": "Coverage",
1304                       "key": "coverage",
1305                       "type": "PERCENT",
1306                     },
1307                     "value": "75.0",
1308                   }
1309                 }
1310               />
1311               <MeasuresOverlayMeasure
1312                 key="line_coverage"
1313                 measure={
1314                   Object {
1315                     "metric": Object {
1316                       "domain": "Coverage",
1317                       "key": "line_coverage",
1318                       "type": "PERCENT",
1319                     },
1320                     "value": "75.0",
1321                   }
1322                 }
1323               />
1324               <MeasuresOverlayMeasure
1325                 key="lines_to_cover"
1326                 measure={
1327                   Object {
1328                     "metric": Object {
1329                       "domain": "Coverage",
1330                       "key": "lines_to_cover",
1331                       "type": "INT",
1332                     },
1333                     "value": "4",
1334                   }
1335                 }
1336               />
1337               <MeasuresOverlayMeasure
1338                 key="uncovered_lines"
1339                 measure={
1340                   Object {
1341                     "metric": Object {
1342                       "domain": "Coverage",
1343                       "key": "uncovered_lines",
1344                       "type": "INT",
1345                     },
1346                     "value": "1",
1347                   }
1348                 }
1349               />
1350             </div>
1351           </div>
1352           <div
1353             className="measures-viewer-card"
1354             key="Reliability"
1355           >
1356             <div
1357               className="measures"
1358             >
1359               <div
1360                 className="measure measure-big"
1361               >
1362                 <span
1363                   className="measure-name"
1364                 >
1365                   metric_domain.Reliability
1366                 </span>
1367               </div>
1368               <MeasuresOverlayMeasure
1369                 key="bugs"
1370                 measure={
1371                   Object {
1372                     "metric": Object {
1373                       "domain": "Reliability",
1374                       "key": "bugs",
1375                       "type": "INT",
1376                     },
1377                     "value": "0",
1378                   }
1379                 }
1380               />
1381               <MeasuresOverlayMeasure
1382                 key="reliability_rating"
1383                 measure={
1384                   Object {
1385                     "metric": Object {
1386                       "domain": "Reliability",
1387                       "key": "reliability_rating",
1388                       "type": "RATING",
1389                     },
1390                     "value": "1.0",
1391                   }
1392                 }
1393               />
1394             </div>
1395           </div>
1396         </div>
1397         <div
1398           className="measures-viewer-section"
1399         >
1400           <div
1401             className="measures-viewer-card"
1402             key="Security"
1403           >
1404             <div
1405               className="measures"
1406             >
1407               <div
1408                 className="measure measure-big"
1409               >
1410                 <span
1411                   className="measure-name"
1412                 >
1413                   metric_domain.Security
1414                 </span>
1415               </div>
1416               <MeasuresOverlayMeasure
1417                 key="security_rating"
1418                 measure={
1419                   Object {
1420                     "metric": Object {
1421                       "domain": "Security",
1422                       "key": "security_rating",
1423                       "type": "RATING",
1424                     },
1425                     "value": "1.0",
1426                   }
1427                 }
1428               />
1429               <MeasuresOverlayMeasure
1430                 key="vulnerabilities"
1431                 measure={
1432                   Object {
1433                     "metric": Object {
1434                       "domain": "Security",
1435                       "key": "vulnerabilities",
1436                       "type": "INT",
1437                     },
1438                     "value": "0",
1439                   }
1440                 }
1441               />
1442             </div>
1443           </div>
1444           <div
1445             className="measures-viewer-card"
1446             key="Tests"
1447           >
1448             <div
1449               className="measures"
1450             >
1451               <div
1452                 className="measure measure-big"
1453               >
1454                 <span
1455                   className="measure-name"
1456                 >
1457                   metric_domain.Tests
1458                 </span>
1459               </div>
1460               <MeasuresOverlayMeasure
1461                 key="skipped_tests"
1462                 measure={
1463                   Object {
1464                     "metric": Object {
1465                       "domain": "Tests",
1466                       "key": "skipped_tests",
1467                       "type": "INT",
1468                     },
1469                     "value": "0",
1470                   }
1471                 }
1472               />
1473               <MeasuresOverlayMeasure
1474                 key="test_errors"
1475                 measure={
1476                   Object {
1477                     "metric": Object {
1478                       "domain": "Tests",
1479                       "key": "test_errors",
1480                       "type": "INT",
1481                     },
1482                     "value": "1",
1483                   }
1484                 }
1485               />
1486               <MeasuresOverlayMeasure
1487                 key="test_failures"
1488                 measure={
1489                   Object {
1490                     "metric": Object {
1491                       "domain": "Tests",
1492                       "key": "test_failures",
1493                       "type": "INT",
1494                     },
1495                     "value": "0",
1496                   }
1497                 }
1498               />
1499               <MeasuresOverlayMeasure
1500                 key="test_success_density"
1501                 measure={
1502                   Object {
1503                     "metric": Object {
1504                       "domain": "Tests",
1505                       "key": "test_success_density",
1506                       "type": "PERCENT",
1507                     },
1508                     "value": "100.0",
1509                   }
1510                 }
1511               />
1512             </div>
1513           </div>
1514           <div
1515             className="measures-viewer-card"
1516             key="Issues"
1517           >
1518             <div
1519               className="measures"
1520             >
1521               <div
1522                 className="measure measure-big"
1523               >
1524                 <span
1525                   className="measure-name"
1526                 >
1527                   metric_domain.Issues
1528                 </span>
1529               </div>
1530               <MeasuresOverlayMeasure
1531                 key="false_positive_issues"
1532                 measure={
1533                   Object {
1534                     "metric": Object {
1535                       "domain": "Issues",
1536                       "key": "false_positive_issues",
1537                       "type": "INT",
1538                     },
1539                     "value": "0",
1540                   }
1541                 }
1542               />
1543               <MeasuresOverlayMeasure
1544                 key="violations"
1545                 measure={
1546                   Object {
1547                     "metric": Object {
1548                       "domain": "Issues",
1549                       "key": "violations",
1550                       "type": "INT",
1551                     },
1552                     "value": "1",
1553                   }
1554                 }
1555               />
1556               <MeasuresOverlayMeasure
1557                 key="wont_fix_issues"
1558                 measure={
1559                   Object {
1560                     "metric": Object {
1561                       "domain": "Issues",
1562                       "key": "wont_fix_issues",
1563                       "type": "INT",
1564                     },
1565                     "value": "0",
1566                   }
1567                 }
1568               />
1569             </div>
1570           </div>
1571           <div
1572             className="measures-viewer-card"
1573             key="Duplications"
1574           >
1575             <div
1576               className="measures"
1577             >
1578               <div
1579                 className="measure measure-big"
1580               >
1581                 <span
1582                   className="measure-name"
1583                 >
1584                   metric_domain.Duplications
1585                 </span>
1586               </div>
1587               <MeasuresOverlayMeasure
1588                 key="duplicated_blocks"
1589                 measure={
1590                   Object {
1591                     "metric": Object {
1592                       "domain": "Duplications",
1593                       "key": "duplicated_blocks",
1594                       "type": "INT",
1595                     },
1596                     "value": "3",
1597                   }
1598                 }
1599               />
1600               <MeasuresOverlayMeasure
1601                 key="duplicated_files"
1602                 measure={
1603                   Object {
1604                     "metric": Object {
1605                       "domain": "Duplications",
1606                       "key": "duplicated_files",
1607                       "type": "INT",
1608                     },
1609                     "value": "1",
1610                   }
1611                 }
1612               />
1613               <MeasuresOverlayMeasure
1614                 key="duplicated_lines"
1615                 measure={
1616                   Object {
1617                     "metric": Object {
1618                       "domain": "Duplications",
1619                       "key": "duplicated_lines",
1620                       "type": "INT",
1621                     },
1622                     "value": "0",
1623                   }
1624                 }
1625               />
1626               <MeasuresOverlayMeasure
1627                 key="duplicated_lines_density"
1628                 measure={
1629                   Object {
1630                     "metric": Object {
1631                       "domain": "Duplications",
1632                       "key": "duplicated_lines_density",
1633                       "type": "PERCENT",
1634                     },
1635                     "value": "0.0",
1636                   }
1637                 }
1638               />
1639             </div>
1640           </div>
1641           <div
1642             className="measures-viewer-card"
1643             key="Maintainability"
1644           >
1645             <div
1646               className="measures"
1647             >
1648               <div
1649                 className="measure measure-big"
1650               >
1651                 <span
1652                   className="measure-name"
1653                 >
1654                   metric_domain.Maintainability
1655                 </span>
1656               </div>
1657               <MeasuresOverlayMeasure
1658                 key="code_smells"
1659                 measure={
1660                   Object {
1661                     "metric": Object {
1662                       "domain": "Maintainability",
1663                       "key": "code_smells",
1664                       "type": "INT",
1665                     },
1666                     "value": "2",
1667                   }
1668                 }
1669               />
1670               <MeasuresOverlayMeasure
1671                 key="sqale_debt_ratio"
1672                 measure={
1673                   Object {
1674                     "metric": Object {
1675                       "domain": "Maintainability",
1676                       "key": "sqale_debt_ratio",
1677                       "type": "PERCENT",
1678                     },
1679                     "value": "16.7",
1680                   }
1681                 }
1682               />
1683               <MeasuresOverlayMeasure
1684                 key="sqale_index"
1685                 measure={
1686                   Object {
1687                     "metric": Object {
1688                       "domain": "Maintainability",
1689                       "key": "sqale_index",
1690                       "type": "WORK_DUR",
1691                     },
1692                     "value": "40",
1693                   }
1694                 }
1695               />
1696             </div>
1697           </div>
1698         </div>
1699       </div>
1700     </div>
1701   </div>
1702   <footer
1703     className="modal-foot"
1704   >
1705     <ResetButtonLink
1706       onClick={[MockFunction]}
1707     >
1708       close
1709     </ResetButtonLink>
1710   </footer>
1711 </Modal>
1712 `;
1713
1714 exports[`should render test file 1`] = `
1715 <Modal
1716   contentLabel="component_viewer.file_measures"
1717   onRequestClose={[MockFunction]}
1718   size="large"
1719 >
1720   <div
1721     className="modal-head"
1722   >
1723     <h2>
1724       component_viewer.file_measures
1725     </h2>
1726   </div>
1727   <div
1728     className="modal-body modal-container"
1729   >
1730     <div
1731       className="measures-viewer-header big-spacer-bottom"
1732     >
1733       <div>
1734         <QualifierIcon
1735           className="little-spacer-right"
1736           qualifier="TRK"
1737         />
1738         <Link
1739           to={
1740             Object {
1741               "pathname": "/dashboard",
1742               "search": "?branch=feature&id=project-key",
1743             }
1744           }
1745         >
1746           Project Name
1747         </Link>
1748       </div>
1749       <div
1750         className="display-flex-center little-spacer-top"
1751       >
1752         <QualifierIcon
1753           className="little-spacer-right"
1754           qualifier="UTS"
1755         />
1756         src/file.js
1757       </div>
1758     </div>
1759     <div
1760       className="measures-viewer"
1761     >
1762       <div
1763         className="measures-viewer-section measures-viewer-section-limited"
1764       >
1765         <div
1766           className="measures-viewer-card"
1767         >
1768           <div
1769             className="measures"
1770           >
1771             <MeasuresOverlayMeasure
1772               key="test_success_density"
1773               measure={
1774                 Object {
1775                   "metric": Object {
1776                     "domain": "Tests",
1777                     "key": "test_success_density",
1778                     "type": "PERCENT",
1779                   },
1780                   "value": "100.0",
1781                 }
1782               }
1783             />
1784             <MeasuresOverlayMeasure
1785               key="test_failures"
1786               measure={
1787                 Object {
1788                   "metric": Object {
1789                     "domain": "Tests",
1790                     "key": "test_failures",
1791                     "type": "INT",
1792                   },
1793                   "value": "0",
1794                 }
1795               }
1796             />
1797             <MeasuresOverlayMeasure
1798               key="test_errors"
1799               measure={
1800                 Object {
1801                   "metric": Object {
1802                     "domain": "Tests",
1803                     "key": "test_errors",
1804                     "type": "INT",
1805                   },
1806                   "value": "1",
1807                 }
1808               }
1809             />
1810             <MeasuresOverlayMeasure
1811               key="skipped_tests"
1812               measure={
1813                 Object {
1814                   "metric": Object {
1815                     "domain": "Tests",
1816                     "key": "skipped_tests",
1817                     "type": "INT",
1818                   },
1819                   "value": "0",
1820                 }
1821               }
1822             />
1823           </div>
1824         </div>
1825       </div>
1826     </div>
1827     <div
1828       className="spacer-top"
1829     >
1830       <a
1831         className="js-show-all-measures"
1832         href="#"
1833         onClick={[Function]}
1834       >
1835         component_viewer.show_all_measures
1836       </a>
1837     </div>
1838   </div>
1839   <footer
1840     className="modal-foot"
1841   >
1842     <ResetButtonLink
1843       onClick={[MockFunction]}
1844     >
1845       close
1846     </ResetButtonLink>
1847   </footer>
1848 </Modal>
1849 `;