Skip to content

Commit 004d85f

Browse files
authored
Merge branch 'master' into rule/add-RSPEC-S7456
2 parents 36fd241 + 0d0544f commit 004d85f

File tree

564 files changed

+13034
-1585
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

564 files changed

+13034
-1585
lines changed

.cirrus.star

Lines changed: 0 additions & 4 deletions
This file was deleted.

.cirrus.yml

Lines changed: 0 additions & 139 deletions
This file was deleted.
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: 'Install common dependencies'
2+
description: 'Install common dependencies for the project'
3+
4+
runs:
5+
using: 'composite'
6+
steps:
7+
- name: Vault
8+
id: artifactory-secrets
9+
uses: SonarSource/vault-action-wrapper@320bd31b03e5dacaac6be51bbbb15adf7caccc32 # v3.1.0
10+
with:
11+
secrets: |
12+
development/artifactory/token/{REPO_OWNER_NAME_DASH}-private-reader access_token | ARTIFACTORY_ACCESS_TOKEN;
13+
- name: Configure npm
14+
shell: bash
15+
env:
16+
ARTIFACTORY_URL: https://repox.jfrog.io
17+
ARTIFACTORY_ACCESS_TOKEN: ${{ fromJSON(steps.artifactory-secrets.outputs.vault).ARTIFACTORY_ACCESS_TOKEN }}
18+
run: |
19+
npm config set registry "$ARTIFACTORY_URL/api/npm/npm"
20+
npm config set "${ARTIFACTORY_URL//https:}/api/npm/:_authToken=$ARTIFACTORY_ACCESS_TOKEN"
21+
- uses: jdx/mise-action@be3be2260bc02bc3fbf94c5e2fed8b7964baf074 # v3.4.0
22+
env:
23+
MISE_PYTHON_DEFAULT_PACKAGES_FILE: ${{ github.workspace }}/ci/mise-default-python-packages
24+
with:
25+
version: 2025.11.3
26+
- name: Setup asciidoctor
27+
shell: bash
28+
run: |
29+
sudo gem install asciidoctor -v 2.0.26
30+
asciidoctor --version

.github/workflows/build.yml

Lines changed: 186 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,186 @@
1+
name: Build
2+
on:
3+
push:
4+
branches:
5+
- master
6+
- branch-*
7+
- dogfood-*
8+
pull_request:
9+
merge_group:
10+
11+
concurrency:
12+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
13+
cancel-in-progress: true
14+
15+
jobs:
16+
tooling_tests:
17+
runs-on: github-ubuntu-latest-s
18+
name: Tooling Tests
19+
permissions:
20+
id-token: write
21+
contents: write
22+
steps:
23+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
24+
with:
25+
fetch-depth: 0
26+
- name: Install common dependencies
27+
uses: ./.github/actions/install-common-dependencies
28+
- name: Vault
29+
id: secrets
30+
uses: SonarSource/vault-action-wrapper@320bd31b03e5dacaac6be51bbbb15adf7caccc32 # v3.1.0
31+
with:
32+
secrets: |
33+
development/kv/data/next url | SONAR_HOST_URL;
34+
development/kv/data/next token | SONAR_TOKEN;
35+
- name: Run tests
36+
working-directory: rspec-tools
37+
run: |
38+
pipenv install --dev
39+
pipenv run pytest --cov=rspec_tools --cov-report=xml
40+
pipenv run black --check rspec_tools tests
41+
pipenv run usort check rspec_tools tests
42+
- name: SonarQube Scan
43+
uses: sonarsource/sonarqube-scan-action@fd88b7d7ccbaefd23d8f36f73b59db7a3d246602 # v6.0.0
44+
with:
45+
projectBaseDir: rspec-tools
46+
env:
47+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
48+
SONAR_TOKEN: ${{ fromJSON(steps.secrets.outputs.vault).SONAR_TOKEN }}
49+
SONAR_HOST_URL: ${{ fromJSON(steps.secrets.outputs.vault).SONAR_HOST_URL }}
50+
51+
frontend_tests:
52+
runs-on: github-ubuntu-latest-s
53+
name: Frontend Tests
54+
permissions:
55+
id-token: write
56+
contents: write
57+
steps:
58+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
59+
with:
60+
fetch-depth: 0
61+
- name: Install common dependencies
62+
uses: ./.github/actions/install-common-dependencies
63+
- name: Setup Node.js cache
64+
uses: SonarSource/gh-action_cache@v1
65+
with:
66+
path: frontend/node_modules
67+
key: node-${{ runner.os }}-${{ hashFiles('frontend/package-lock.json') }}
68+
restore-keys: |
69+
node-${{ runner.os }}-
70+
- name: Install dependencies
71+
working-directory: frontend
72+
run: npm install
73+
- name: Vault
74+
id: secrets
75+
uses: SonarSource/vault-action-wrapper@320bd31b03e5dacaac6be51bbbb15adf7caccc32 # v3.1.0
76+
with:
77+
secrets: |
78+
development/kv/data/next url | SONAR_HOST_URL;
79+
development/kv/data/next token | SONAR_TOKEN;
80+
- name: Run tests
81+
working-directory: frontend
82+
run: |
83+
npm run build
84+
npm test -- --reporter=verbose --coverage
85+
- name: SonarQube Scan
86+
uses: sonarsource/sonarqube-scan-action@fd88b7d7ccbaefd23d8f36f73b59db7a3d246602 # v6.0.0
87+
with:
88+
projectBaseDir: frontend
89+
env:
90+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
91+
SONAR_TOKEN: ${{ fromJSON(steps.secrets.outputs.vault).SONAR_TOKEN }}
92+
SONAR_HOST_URL: ${{ fromJSON(steps.secrets.outputs.vault).SONAR_HOST_URL }}
93+
94+
validate_ci_tests:
95+
runs-on: github-ubuntu-latest-s
96+
name: Validate CI Tests
97+
permissions:
98+
id-token: write
99+
contents: write
100+
steps:
101+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
102+
with:
103+
fetch-depth: 0
104+
- uses: dorny/paths-filter@v3
105+
id: changes
106+
with:
107+
filters: |
108+
ci_tests:
109+
- 'ci_tests/**'
110+
ci:
111+
- 'ci/**'
112+
- name: Install common dependencies
113+
if: steps.changes.outputs.ci_tests == 'true' || steps.changes.outputs.ci == 'true'
114+
uses: ./.github/actions/install-common-dependencies
115+
- name: Run CI tests
116+
if: steps.changes.outputs.ci_tests == 'true' || steps.changes.outputs.ci == 'true'
117+
run: ./ci_tests/asciidoc_validation/run_tests.sh
118+
119+
validate_rules:
120+
runs-on: github-ubuntu-latest-s
121+
name: Validate Rules
122+
permissions:
123+
id-token: write
124+
contents: write
125+
steps:
126+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
127+
with:
128+
fetch-depth: 0
129+
- name: Install common dependencies
130+
uses: ./.github/actions/install-common-dependencies
131+
- name: Validate metadata
132+
env:
133+
GITHUB_DEFAULT_BRANCH: ${{ github.event.repository.default_branch }}
134+
run: ./ci/validate_metadata.sh
135+
- name: Validate file extensions
136+
run: ./ci/validate_file_extensions.sh
137+
- name: Validate AsciiDoc
138+
env:
139+
GITHUB_DEFAULT_BRANCH: ${{ github.event.repository.default_branch }}
140+
run: ./ci/validate_asciidoc.sh
141+
142+
validate_links:
143+
if: github.event_name != 'merge_group'
144+
runs-on: github-ubuntu-latest-s
145+
name: Validate Links
146+
timeout-minutes: 120
147+
permissions:
148+
id-token: write
149+
contents: write
150+
steps:
151+
- uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
152+
with:
153+
fetch-depth: 0
154+
- name: Install common dependencies
155+
uses: ./.github/actions/install-common-dependencies
156+
- name: Restore link cache
157+
id: cache-link-restore
158+
uses: actions/cache/restore@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
159+
with:
160+
path: link-probing.cache
161+
key: link-probing-cache-${{ github.sha }}
162+
restore-keys: |
163+
link-probing-cache-${{ github.sha }}
164+
link-probing-cache-
165+
- name: Validate links
166+
run: |
167+
./ci/validate_links.sh link-probing.cache
168+
- name: Save link cache
169+
if: always() && !cancelled()
170+
id: cache-link-save
171+
uses: actions/cache/save@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
172+
with:
173+
path: link-probing.cache
174+
key: link-probing-cache-${{ github.sha }}
175+
176+
all_required_checks:
177+
needs:
178+
- tooling_tests
179+
- frontend_tests
180+
- validate_rules
181+
- validate_ci_tests
182+
runs-on: github-ubuntu-latest-s
183+
name: all_required_checks
184+
steps:
185+
- name: All required checks passed
186+
run: echo 'All required checks have passed'

.github/workflows/main.yml

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,26 @@ jobs:
1515
contents: write # Get the contents of open new-rule PRs, the 'master' with updated-coverage from 'dogfood-automerge'; write to 'gh-pages' branch
1616
steps:
1717
- name: Checkout 🛎️
18-
uses: actions/checkout@v4 # If you're using actions/checkout you must set persist-credentials to false in most cases for the deployment to work correctly.
18+
uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0
1919
with:
2020
persist-credentials: false
2121
ref: 'dogfood-automerge'
2222

23+
- name: Vault
24+
id: secrets
25+
uses: SonarSource/vault-action-wrapper@320bd31b03e5dacaac6be51bbbb15adf7caccc32 # v3.1.0
26+
with:
27+
secrets: |
28+
development/artifactory/token/{REPO_OWNER_NAME_DASH}-private-reader access_token | ARTIFACTORY_ACCESS_TOKEN;
29+
30+
- name: Configure npm
31+
env:
32+
ARTIFACTORY_URL: https://repox.jfrog.io
33+
ARTIFACTORY_ACCESS_TOKEN: ${{ fromJSON(steps.secrets.outputs.vault).ARTIFACTORY_ACCESS_TOKEN }}
34+
run: |
35+
npm config set registry "$ARTIFACTORY_URL/api/npm/npm"
36+
npm config set "${ARTIFACTORY_URL//https:}/api/npm/:_authToken=$ARTIFACTORY_ACCESS_TOKEN"
37+
2338
- name: Install and Build 🔧 # This example project is built using npm and outputs the result to the 'build' folder. Replace with the commands required to build your project, or remove this step entirely if your site is pre-built.
2439
working-directory: frontend
2540
run: |

0 commit comments

Comments
 (0)