]> source.dussan.org Git - sonarqube.git/blob
ef6da9199ce6d6a918632470bc76f318acb7be6a
[sonarqube.git] /
1 // Jest Snapshot v1, https://goo.gl/fbAQLP
2
3 exports[`should render correctly 1`] = `
4 <Fragment>
5   <DefaultProjectKey
6     component={
7       {
8         "breadcrumbs": [],
9         "key": "my-project",
10         "name": "MyProject",
11         "qualifier": "TRK",
12         "qualityGate": {
13           "isDefault": true,
14           "key": "30",
15           "name": "Sonar way",
16         },
17         "qualityProfiles": [
18           {
19             "deleted": false,
20             "key": "my-qp",
21             "language": "ts",
22             "name": "Sonar way",
23           },
24         ],
25         "tags": [],
26       }
27     }
28   />
29   <CreateYmlFile
30     yamlFileName=".github/workflows/build.yml"
31     yamlTemplate="name: Build
32
33 on:
34   push:
35     branches:
36       - main
37   pull_request:
38     types: [opened, synchronize, reopened]
39
40 jobs:
41   build:
42     name: Build
43     runs-on: ubuntu-latest
44     steps:
45       - uses: actions/checkout@v2
46         with:
47           fetch-depth: 0  # Shallow clones should be disabled for a better relevancy of analysis
48       - uses: sonarsource/sonarqube-scan-action@master
49         env:
50           SONAR_TOKEN: \${{ secrets.SONAR_TOKEN }}
51           SONAR_HOST_URL: \${{ secrets.SONAR_HOST_URL }}
52       # If you wish to fail your job when the Quality Gate is red, uncomment the
53       # following lines. This would typically be used to fail a deployment.
54       # We do not recommend to use this in a pull request. Prefer using pull request
55       # decoration instead.
56       # - uses: sonarsource/sonarqube-quality-gate-action@master
57       #   timeout-minutes: 5
58       #   env:
59       #     SONAR_TOKEN: \${{ secrets.SONAR_TOKEN }}"
60   />
61   <FinishButton
62     onClick={[MockFunction]}
63   />
64 </Fragment>
65 `;
66
67 exports[`should render correctly: without branch enabled 1`] = `
68 <Fragment>
69   <DefaultProjectKey
70     component={
71       {
72         "breadcrumbs": [],
73         "key": "my-project",
74         "name": "MyProject",
75         "qualifier": "TRK",
76         "qualityGate": {
77           "isDefault": true,
78           "key": "30",
79           "name": "Sonar way",
80         },
81         "qualityProfiles": [
82           {
83             "deleted": false,
84             "key": "my-qp",
85             "language": "ts",
86             "name": "Sonar way",
87           },
88         ],
89         "tags": [],
90       }
91     }
92   />
93   <CreateYmlFile
94     yamlFileName=".github/workflows/build.yml"
95     yamlTemplate="name: Build
96
97 on:
98   push:
99     branches:
100       - main
101
102
103 jobs:
104   build:
105     name: Build
106     runs-on: ubuntu-latest
107     steps:
108       - uses: actions/checkout@v2
109         with:
110           fetch-depth: 0  # Shallow clones should be disabled for a better relevancy of analysis
111       - uses: sonarsource/sonarqube-scan-action@master
112         env:
113           SONAR_TOKEN: \${{ secrets.SONAR_TOKEN }}
114           SONAR_HOST_URL: \${{ secrets.SONAR_HOST_URL }}
115       # If you wish to fail your job when the Quality Gate is red, uncomment the
116       # following lines. This would typically be used to fail a deployment.
117       # - uses: sonarsource/sonarqube-quality-gate-action@master
118       #   timeout-minutes: 5
119       #   env:
120       #     SONAR_TOKEN: \${{ secrets.SONAR_TOKEN }}"
121   />
122   <FinishButton
123     onClick={[MockFunction]}
124   />
125 </Fragment>
126 `;