[git] GnuPG - branch, master, updated. gnupg-2.1.22-24-gb0112db

by Justus Winter cvs at cvs.gnupg.org
Mon Aug 7 11:21:04 CEST 2017


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "The GNU Privacy Guard".

The branch, master has been updated
       via  b0112dbca91e720a4ff622ad0e88d99eba56203a (commit)
      from  a611cba142470c52f3303c512f77ae7d195cc41f (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit b0112dbca91e720a4ff622ad0e88d99eba56203a
Author: Justus Winter <justus at g10code.com>
Date:   Mon Aug 7 11:15:56 2017 +0200

    tests: Do not run all tests unless in maintainer mode.
    
    * configure.ac: Leak the maintainer mode flag into 'config.h'.
    * tests/gpgscm/ffi.c: Pass it into the scheme environment.
    * tests/openpgp/all-tests.scm: Only run tests against non-default
    configurations (keyring, extended-key-format) in maintainer mode.
    --
    
    Werner is concerned that the tests do take up too much time and asked
    me to reduce the runtime of the tests for normal users.
    
    Signed-off-by: Justus Winter <justus at g10code.com>

diff --git a/configure.ac b/configure.ac
index 18e6c09..20a6ed6 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1541,6 +1541,11 @@ if test "$development_version" = yes; then
             [Defined if this is not a regular release])
 fi
 
+if test "$USE_MAINTAINER_MODE" = "yes"; then
+    AC_DEFINE(MAINTAINER_MODE,1,
+            [Defined if this build is in maintainer mode])
+fi
+
 AM_CONDITIONAL(CROSS_COMPILING, test x$cross_compiling = xyes)
 
 GNUPG_CHECK_GNUMAKE
diff --git a/tests/gpgscm/ffi.c b/tests/gpgscm/ffi.c
index 4c03ba6..4c2148a 100644
--- a/tests/gpgscm/ffi.c
+++ b/tests/gpgscm/ffi.c
@@ -1442,6 +1442,14 @@ ffi_init (scheme *sc, const char *argv0, const char *scriptname,
 #endif
               );
 
+  ffi_define (sc, "*maintainer-mode*",
+#if MAINTAINER_MODE
+              sc->T
+#else
+              sc->F
+#endif
+              );
+
 
   ffi_define (sc, "*stdin*",
               sc->vptr->mk_port_from_file (sc, stdin, port_input));
diff --git a/tests/openpgp/all-tests.scm b/tests/openpgp/all-tests.scm
index 4dd6d6f..e65d527 100644
--- a/tests/openpgp/all-tests.scm
+++ b/tests/openpgp/all-tests.scm
@@ -51,18 +51,28 @@
    (parse-makefile-expand (in-srcdir "tests" "openpgp" "Makefile.am")
 			  (lambda (filename port key) (parse-makefile port key))
 			  "XTESTS"))
- (append
-  (map (lambda (name)
-	 (test::scm setup
-		    (path-join "tests" "openpgp" name)
-		    (in-srcdir "tests" "openpgp" name))) all-tests)
-  (map (lambda (name)
-	 (test::scm setup-use-keyring
-		    (qualify (path-join "tests" "openpgp" name) "use-keyring")
-		    (in-srcdir "tests" "openpgp" name)
-		    "--use-keyring")) all-tests)
-  (map (lambda (name)
-	 (test::scm setup-extended-key-format
-		    (qualify (path-join "tests" "openpgp" name) "extended-key-format")
-		    (in-srcdir "tests" "openpgp" name)
-		    "--extended-key-format")) all-tests)))
+
+ (define tests
+   (map (lambda (name)
+	  (test::scm setup
+		     (path-join "tests" "openpgp" name)
+		     (in-srcdir "tests" "openpgp" name))) all-tests))
+
+ (when *maintainer-mode*
+       (set! tests
+	     (append
+	      tests
+	      (map (lambda (name)
+		     (test::scm setup-use-keyring
+				(qualify (path-join "tests" "openpgp" name)
+					 "use-keyring")
+				(in-srcdir "tests" "openpgp" name)
+				"--use-keyring")) all-tests)
+	      (map (lambda (name)
+		     (test::scm setup-extended-key-format
+				(qualify (path-join "tests" "openpgp" name)
+					 "extended-key-format")
+				(in-srcdir "tests" "openpgp" name)
+				"--extended-key-format")) all-tests))))
+
+ tests)

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

Summary of changes:
 configure.ac                |  5 +++++
 tests/gpgscm/ffi.c          |  8 ++++++++
 tests/openpgp/all-tests.scm | 40 +++++++++++++++++++++++++---------------
 3 files changed, 38 insertions(+), 15 deletions(-)


hooks/post-receive
-- 
The GNU Privacy Guard
http://git.gnupg.org




More information about the Gnupg-commits mailing list