abcxyz / abc

Apache License 2.0
12 stars 3 forks source link

Attempt to get dependabot to run `abc templates golden-test record` #496

Open drevell opened 7 months ago

drevell commented 7 months ago

As an abc developer, I want dependabot to be able to automatically upgrade insecure dependencies in my go.mod.

Currently, if a template outputs a go.mod file, dependabot will send a PR that tries to update go.mod, but that PR may fail the golden-test presubmit. The golden-test verify command expects an exact match of the template output with the recorded "snapshot" in the testdata directory. That snapshot still expects the old (insecure) version of the dependency.

I don't know if there's a way to address this other than manually running abc templates golden-test record for each dependabot PR. It would be neat if we could configure dependabot to run a script to re-record golden tests and commit the result into its PR. I don't know enough about dependabot to know if that's possible.