| 1 |
From: Andrew Ruthven <[email protected]> |
| 2 |
Subject: Ensure that we have some dummy "binaries" around for testing. |
| 3 |
The test scripts require that gpg1, gpg and gnupg all exist and are |
| 4 |
executable, otherwise warnings will be thrown. |
| 5 |
|
| 6 |
This patch provides those "binaries", but they actually only print the |
| 7 |
a version number that matches the binary. |
| 8 |
|
| 9 |
It is still necessary to have at least one real GnuPG binary installed |
| 10 |
for the test suite to pass. For Debian, but gpg and gpg1 need to be |
| 11 |
present. |
| 12 |
|
| 13 |
The patch to t/update_version.t isn't required on Debian, but is included |
| 14 |
as this patch set has been forwarded upstream, and may be required |
| 15 |
elsewhere. This is also why dummy scripts for gpg, gpg1 and gnupg are |
| 16 |
provided. |
| 17 |
Bug: https://rt.cpan.org/Ticket/Display.html?id=133039 |
| 18 |
Last-Update: 2020-07-23 |
| 19 |
|
| 20 |
--- |
| 21 |
This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ |
| 22 |
--- a/t/Interface.t |
| 23 |
+++ b/t/Interface.t |
| 24 |
@@ -8,6 +8,10 @@ |
| 25 |
use lib './t'; |
| 26 |
use MyTest; |
| 27 |
|
| 28 |
+# Make sure that there are some dummy scripts available so no warnings |
| 29 |
+# are thrown. |
| 30 |
+$ENV{PATH} .= ":t/bin"; |
| 31 |
+ |
| 32 |
use GnuPG::Interface; |
| 33 |
|
| 34 |
my $v1 = './test/fake-gpg-v1'; |
| 35 |
--- /dev/null |
| 36 |
+++ b/t/bin/gnupg |
| 37 |
@@ -0,0 +1,3 @@ |
| 38 |
+#!/bin/sh |
| 39 |
+ |
| 40 |
+echo "gpg (GnuPG) 2.2.20" |
| 41 |
--- /dev/null |
| 42 |
+++ b/t/bin/gpg |
| 43 |
@@ -0,0 +1,3 @@ |
| 44 |
+#!/bin/sh |
| 45 |
+ |
| 46 |
+echo "gpg (GnuPG) 2.2.20" |
| 47 |
--- /dev/null |
| 48 |
+++ b/t/bin/gpg1 |
| 49 |
@@ -0,0 +1,3 @@ |
| 50 |
+#!/bin/sh |
| 51 |
+ |
| 52 |
+echo "gpg (GnuPG) 1.4.23" |
| 53 |
--- a/t/update_version.t |
| 54 |
+++ b/t/update_version.t |
| 55 |
@@ -14,6 +14,10 @@ |
| 56 |
use lib './t'; |
| 57 |
use MyTest; |
| 58 |
|
| 59 |
+# Make sure that there are some dummy scripts available so no warnings |
| 60 |
+# are thrown. |
| 61 |
+$ENV{PATH} .= ":t/bin"; |
| 62 |
+ |
| 63 |
use GnuPG::Interface; |
| 64 |
|
| 65 |
my $gnupg = GnuPG::Interface->new(); |