Suppress insecure memory warnings

This commit is contained in:
Tim Byrne 2019-12-03 10:40:40 -06:00
parent 437ae2b719
commit 397d45ccd0
No known key found for this signature in database
GPG Key ID: 14DB4FC2465A4B12
1 changed files with 6 additions and 3 deletions

View File

@ -567,12 +567,15 @@ def gnupg(tmpdir_factory, runner):
home = tmpdir_factory.mktemp('gnupghome')
home.chmod(0o700)
conf = home.join('gpg-agent.conf')
conf.write(
conf = home.join('gpg.conf')
conf.write('no-secmem-warning\n')
conf.chmod(0o600)
agentconf = home.join('gpg-agent.conf')
agentconf.write(
f'pinentry-program {os.path.abspath("test/pinentry-mock")}\n'
'max-cache-ttl 0\n'
)
conf.chmod(0o600)
agentconf.chmod(0o600)
data = collections.namedtuple('GNUPG', ['home', 'pw'])
env = os.environ.copy()
env['GNUPGHOME'] = home