Browse Source

contrib: Update contributing checklist for config

pull/9451/head
Daniel Nephin 4 years ago
parent
commit
5a3814b0f7
  1. 8
      contributing/checklist-adding-config-fields.md

8
contributing/checklist-adding-config-fields.md

@ -29,10 +29,10 @@ There are four specific cases covered with increasing complexity:
`agent/config/runtime.go`.
- [ ] Add an appropriate parser/setter in `agent/config/builder.go` to
translate.
- [ ] Add the new field with a random value to both the JSON and HCL blobs in
`TestFullConfig` in `agent/config/runtime_test.go`, it should fail now, then
add the same random value to the expected struct in that test so it passes
again.
- [ ] Add the new field with a random value to both the JSON and HCL files in
`agent/config/testdata/full-config.*`, which should cause the test to fail.
Then update the expected value in `TestLoad_FullConfig` in
`agent/config/runtime_test.go` to make the test pass again.
- [ ] Run `go test -run TestRuntimeConfig_Sanitize ./agent/config -update` to update
the expected value for `TestRuntimeConfig_Sanitize`. Look at `git diff` to
make sure the value changed as you expect.

Loading…
Cancel
Save