]> source.dussan.org Git - sonarqube.git/blob
2977276f8b698f3df44034ed5fdf55ec8f5438b0
[sonarqube.git] /
1 // Jest Snapshot v1, https://goo.gl/fbAQLP
2
3 exports[`should render correctly for a branch 1`] = `
4 <Fragment>
5   <div
6     className="display-flex-center flex-0 small"
7   >
8     <span
9       className="header-meta-warnings"
10     >
11       <ComponentNavWarnings
12         componentKey="my-project"
13         isBranch={true}
14         onWarningDismiss={[MockFunction]}
15         warnings={
16           [
17             {
18               "dismissable": false,
19               "key": "foo",
20               "message": "ERROR_1",
21             },
22             {
23               "dismissable": false,
24               "key": "foo",
25               "message": "ERROR_2",
26             },
27           ]
28         }
29       />
30     </span>
31     <span
32       className="spacer-left nowrap note"
33       title="overview.project.last_analysis.date_time.2017-01-02T00:00:00.000Z"
34     >
35       2017-01-02T00:00:00.000Z
36     </span>
37     <span
38       className="spacer-left nowrap note"
39     >
40       version 0.0.1
41     </span>
42     <withCurrentUserContext(HomePageSelect)
43       className="spacer-left"
44       currentPage={
45         {
46           "branch": "branch-6.7",
47           "component": "my-project",
48           "type": "PROJECT",
49         }
50       }
51     />
52   </div>
53 </Fragment>
54 `;
55
56 exports[`should render correctly for a main project branch 1`] = `
57 <Fragment>
58   <div
59     className="display-flex-center flex-0 small"
60   >
61     <span
62       className="header-meta-warnings"
63     >
64       <ComponentNavWarnings
65         componentKey="my-project"
66         isBranch={true}
67         onWarningDismiss={[MockFunction]}
68         warnings={
69           [
70             {
71               "dismissable": false,
72               "key": "foo",
73               "message": "ERROR_1",
74             },
75             {
76               "dismissable": false,
77               "key": "foo",
78               "message": "ERROR_2",
79             },
80           ]
81         }
82       />
83     </span>
84     <span
85       className="spacer-left nowrap note"
86       title="overview.project.last_analysis.date_time.2017-01-02T00:00:00.000Z"
87     >
88       2017-01-02T00:00:00.000Z
89     </span>
90     <span
91       className="spacer-left nowrap note"
92     >
93       version 0.0.1
94     </span>
95     <withCurrentUserContext(HomePageSelect)
96       className="spacer-left"
97       currentPage={
98         {
99           "branch": undefined,
100           "component": "my-project",
101           "type": "PROJECT",
102         }
103       }
104     />
105   </div>
106 </Fragment>
107 `;
108
109 exports[`should render correctly for a portfolio 1`] = `
110 <Fragment>
111   <div
112     className="display-flex-center flex-0 small"
113   >
114     <span
115       className="header-meta-warnings"
116     >
117       <ComponentNavWarnings
118         componentKey="foo"
119         isBranch={true}
120         onWarningDismiss={[MockFunction]}
121         warnings={
122           [
123             {
124               "dismissable": false,
125               "key": "foo",
126               "message": "ERROR_1",
127             },
128             {
129               "dismissable": false,
130               "key": "foo",
131               "message": "ERROR_2",
132             },
133           ]
134         }
135       />
136     </span>
137     <withCurrentUserContext(HomePageSelect)
138       className="spacer-left"
139       currentPage={
140         {
141           "component": "foo",
142           "type": "PORTFOLIO",
143         }
144       }
145     />
146   </div>
147 </Fragment>
148 `;
149
150 exports[`should render correctly for a pull request 1`] = `
151 <Fragment>
152   <div
153     className="display-flex-center flex-0 small"
154   >
155     <span
156       className="header-meta-warnings"
157     >
158       <ComponentNavWarnings
159         componentKey="my-project"
160         isBranch={false}
161         onWarningDismiss={[MockFunction]}
162         warnings={
163           [
164             {
165               "dismissable": false,
166               "key": "foo",
167               "message": "ERROR_1",
168             },
169             {
170               "dismissable": false,
171               "key": "foo",
172               "message": "ERROR_2",
173             },
174           ]
175         }
176       />
177     </span>
178     <span
179       className="spacer-left nowrap note"
180       title="overview.project.last_analysis.date_time.2017-01-02T00:00:00.000Z"
181     >
182       2017-01-02T00:00:00.000Z
183     </span>
184   </div>
185   <div
186     className="navbar-context-meta-secondary display-inline-flex-center"
187   >
188     <ForwardRef(Link)
189       className="link-no-underline big-spacer-right"
190       size={12}
191       target="_blank"
192       to="https://example.com/pull/1234"
193     >
194       branches.see_the_pr
195     </ForwardRef(Link)>
196     <withBranchStatus(BranchStatus)
197       branchLike={
198         {
199           "analysisDate": "2018-01-01",
200           "base": "master",
201           "branch": "feature/foo/bar",
202           "key": "1001",
203           "target": "master",
204           "title": "Foo Bar feature",
205           "url": "https://example.com/pull/1234",
206         }
207       }
208       component={
209         {
210           "analysisDate": "2017-01-02T00:00:00.000Z",
211           "breadcrumbs": [],
212           "key": "my-project",
213           "name": "MyProject",
214           "qualifier": "TRK",
215           "qualityGate": {
216             "isDefault": true,
217             "key": "30",
218             "name": "Sonar way",
219           },
220           "qualityProfiles": [
221             {
222               "deleted": false,
223               "key": "my-qp",
224               "language": "ts",
225               "name": "Sonar way",
226             },
227           ],
228           "tags": [],
229           "version": "0.0.1",
230         }
231       }
232     />
233   </div>
234 </Fragment>
235 `;