mirror of
https://github.com/coder/coder.git
synced 2026-09-24 15:04:27 +08:00
chore(Makefile): update golden files as part of make gen (#17039)
Updating golden files is an unnecessary extra step in addition to gen that is easily overlooked, leading to the developer noticing the issue in CI leading to lost developer time waiting for tests to complete.
This commit is contained in:
@@ -267,18 +267,15 @@ jobs:
|
||||
popd
|
||||
|
||||
- name: make gen
|
||||
# no `-j` flag as `make` fails with:
|
||||
# coderd/rbac/object_gen.go:1:1: syntax error: package statement must be first
|
||||
run: "make --output-sync -B gen"
|
||||
|
||||
- name: make update-golden-files
|
||||
run: |
|
||||
# Remove golden files to detect discrepancy in generated files.
|
||||
make clean/golden-files
|
||||
# Notifications require DB, we could start a DB instance here but
|
||||
# let's just restore for now.
|
||||
git checkout -- coderd/notifications/testdata/rendered-templates
|
||||
# As above, skip `-j` flag.
|
||||
make --output-sync -B update-golden-files
|
||||
# no `-j` flag as `make` fails with:
|
||||
# coderd/rbac/object_gen.go:1:1: syntax error: package statement must be first
|
||||
make --output-sync -B gen
|
||||
|
||||
- name: Check for unstaged files
|
||||
run: ./scripts/check_unstaged.sh
|
||||
|
||||
Reference in New Issue
Block a user