Closed ddiss closed 1 year ago
I've implemented this via the linked commit. With go there only appears to be a file level constructor (no destructor), so the key is retained in memory after generation in init()
. Tests subsequently use the in-memory key via gpg --import
.
We currently call
gpgInit() -> gpg --gen-key ...
in each test. Doing so is slow and wastes host entropy. We should be able to do this as part of a globalfunc init()
inicyci_test.go
. It would likely also make sense to move.gitconfig
initialisation into the same function.