HUGO

How to regenerate files in testdata/golden?

Hey folks!

There are files in resources/testdata/golden that appear to be generated. This isn’t the only directory like this either. How would we regenerate those files?

I saw in the latest release (v0.86.0) that there’s a PR that touches these files. In it Bep says that they need to be generated but I can’t find how it’s done. Running mage -v generate doesn’t seem to do the trick here.

Thanks in advance.

That should not be needed to do for the “end user”, but if we change some image processing “thing”, then there is 2 flags in two tets:

That needs to 1. Be set to true 2. Run test. 3. Look in the folder printed to console for the images. 4. Copy them to golden. 4. Verify the result.

1 Like

Exactly what I needed. Thank you.