Skip to content

Commit 3551ee3

Browse files
Remove release branch staleness tests.
These are now covered by our daily testing of release branches
1 parent d9b08d7 commit 3551ee3

File tree

2 files changed

+4
-48
lines changed

2 files changed

+4
-48
lines changed

.github/scripts/validate_yaml.py

Lines changed: 0 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -65,35 +65,3 @@
6565
% (step['name'], job)
6666
)
6767
print('PASSED: All steps in all jobs check the continuous-run condition.')
68-
69-
# Check to make sure the list of included branches matches the list of excluded
70-
# branches in staleness_check.yml.
71-
with open(
72-
os.path.join(os.path.dirname(__file__), '../workflows/staleness_check.yml'),
73-
'r',
74-
) as f:
75-
regex_pattern = r"'(\d+\.x)'"
76-
data = yaml.safe_load(f)
77-
matrix = data['jobs']['test']['strategy']['matrix']
78-
included_branches = matrix['branch']
79-
# Main should be included in all test runs
80-
included_branches.remove('main')
81-
excludes = matrix['exclude']
82-
for entry in excludes:
83-
match = re.search(regex_pattern, entry['branch'])
84-
branch = match.group(1)
85-
if branch not in included_branches:
86-
raise ValueError(
87-
'Branch %s is excluded for presubmit runs but is not in the list of'
88-
' matrix branches in staleness_check.yml.' % branch
89-
)
90-
included_branches.remove(branch)
91-
if included_branches:
92-
raise ValueError(
93-
'Branches %s are in the list of matrix branches but do not get excluded'
94-
' for presubmit runs in staleness_check.yml.' % included_branches
95-
)
96-
print(
97-
'PASSED: The list of included branches matches the list of excluded'
98-
' branches in staleness_check.yml.'
99-
)

.github/workflows/staleness_check.yml

Lines changed: 4 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -20,26 +20,14 @@ on:
2020
permissions: {}
2121
jobs:
2222
test:
23-
strategy:
24-
fail-fast: false
25-
matrix:
26-
# TODO Remove this parameterization once the release branch testing is stable.
27-
branch: [main, 25.x, 27.x, 28.x]
28-
os: [{ name: Linux, value: ubuntu-latest}]
29-
exclude:
30-
# If we are in a presubmit run, only test main
31-
- branch: ${{ !inputs.continuous-run && '25.x' }}
32-
- branch: ${{ !inputs.continuous-run && '27.x' }}
33-
- branch: ${{ !inputs.continuous-run && '28.x' }}
34-
35-
name: Test staleness ${{ matrix.os.name }} ${{ github.head_ref && 'PR' || matrix.branch }}
36-
runs-on: ${{ matrix.os.value }}
23+
name: Test staleness
24+
runs-on: ubuntu-latest
3725
if: ${{ github.event.repository.full_name == 'protocolbuffers/protobuf' }}
3826
steps:
39-
- name: Checkout ${{ github.head_ref && 'PR' || matrix.branch }}
27+
- name: Checkout
4028
uses: protocolbuffers/protobuf-ci/checkout@v3
4129
with:
42-
ref: ${{ inputs.safe-checkout || github.head_ref || matrix.branch }}
30+
ref: ${{ inputs.safe-checkout || github.head_ref || github.ref }}
4331

4432
- name: Mark runs associated with commits
4533
if: ${{ github.event_name != 'schedule' && github.event_name != 'workflow_dispatch' }}

0 commit comments

Comments
 (0)