consul/.github/workflows/goldenfile-checker.yml
John Maguire bc4c479a31
[NET-10737] Add CI Checks for Generated Testdata (#21613)
* Add checks to CI to ensure that generated golden files for xds tests are up to date

* fix file permissions

* debugging

* more debugging

* more debugging

* more debugging

* more debugging

* I can't type

* this might be correct

* removing debug prints
2024-08-19 11:49:05 -04:00

31 lines
933 B
YAML

# Copyright (c) HashiCorp, Inc.
# SPDX-License-Identifier: MPL-2.0
# This workflow checks that are no changes necessary to golden files for xds
# tests ensuring they are up to date
name: Golden File Checker
on:
pull_request:
types: [opened, synchronize, labeled]
# Runs on PRs to main and all release branches
branches:
- main
- release/*
jobs:
# checks that there is no diff between the existing golden files
goldenfile-check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4
with:
ref: ${{ github.event.pull_request.head.sha }}
fetch-depth: 0 # by default the checkout action doesn't checkout all branches
- name: Check for golden file xds tests in diff
run: ./.github/scripts/goldenfile_checker.sh
env:
GITHUB_BRANCH_REF: ${{ github.event.pull_request.head.ref }}