[Bps-public-commit] GnuPG-Interface branch, work-with-both-gnupgs, updated. 0.52-29-g43a7081

Brian Duggan brian at bestpractical.com
Wed Mar 28 16:42:07 EDT 2018


The branch, work-with-both-gnupgs has been updated
       via  43a708122e272aef0f059dc79f6098261ae66e81 (commit)
      from  d39f8114e44dbc667f8121c1fe1a00d03b8e497c (commit)

Summary of changes:
 t/zzz_cleanup.t | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

- Log -----------------------------------------------------------------
commit 43a708122e272aef0f059dc79f6098261ae66e81
Author: Brian C. Duggan <brian at bestpractical.com>
Date:   Tue Mar 27 19:59:40 2018 -0400

    Run all test cleanup except gpg-agent cleanup for <= 2.1.0
    
    Run the test cleanup for all GnuPG versions. Don't run gpg-agent part of
    the cleanup for GnuPG <= 2.1.0.

diff --git a/t/zzz_cleanup.t b/t/zzz_cleanup.t
index 6029b5d..e7583af 100644
--- a/t/zzz_cleanup.t
+++ b/t/zzz_cleanup.t
@@ -11,15 +11,16 @@ use File::Path qw (remove_tree);
 # this is actually no test, just cleanup.
 TEST
 {
-    return 1 unless $gnupg->cmp_version($gnupg->version, '2.1') >= 0;
     my $homedir = $gnupg->options->homedir();
     my $err = [];
     # kill off any long-lived gpg-agent, ignoring errors.
     # gpgconf versions < 2.1.11 do not support '--homedir', but still
     # respect the GNUPGHOME environment variable
-    $ENV{'GNUPGHOME'} = $homedir;
-    system('gpgconf', '--quiet', '--kill', 'gpg-agent');
-    delete $ENV{'GNUPGHOME'};
+    if ($gnupg->cmp_version($gnupg->version, '2.1') >= 0) {
+        $ENV{'GNUPGHOME'} = $homedir;
+        system('gpgconf', '--quiet', '--kill', 'gpg-agent');
+        delete $ENV{'GNUPGHOME'};
+    }
     remove_tree($homedir, {error => \$err});
     unlink('test/gnupghome');
     return ! @$err;

-----------------------------------------------------------------------


More information about the Bps-public-commit mailing list