1
0
mirror of git://git.gnupg.org/gnupg.git synced 2024-11-11 21:48:50 +01:00

w32: Exclude tests with HOME.

* common/t-session-env.c [HAVE_W32_SYSTEM] (test_all): HOME is not
defined, so, exclude the tests.

--

Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
This commit is contained in:
NIIBE Yutaka 2022-04-06 13:28:15 +09:00
parent 39d478f5ba
commit b47a23f5fa

View File

@ -154,6 +154,7 @@ test_all (void)
listall (se); listall (se);
#ifndef HAVE_W32_SYSTEM
/* Retrieve a default one. */ /* Retrieve a default one. */
s = session_env_getenv_or_default (se, "HOME", NULL); s = session_env_getenv_or_default (se, "HOME", NULL);
if (!s) if (!s)
@ -161,14 +162,17 @@ test_all (void)
fprintf (stderr, "failed to get default of HOME\n"); fprintf (stderr, "failed to get default of HOME\n");
exit (1); exit (1);
} }
#endif
s = session_env_getenv (se, "HOME"); s = session_env_getenv (se, "HOME");
if (s) if (s)
fail(0); /* This is a default value, thus we should not see it. */ fail(0); /* This is a default value, thus we should not see it. */
#ifndef HAVE_W32_SYSTEM
s = session_env_getenv_or_default (se, "HOME", NULL); s = session_env_getenv_or_default (se, "HOME", NULL);
if (!s) if (!s)
fail(0); /* But here we should see it. */ fail(0); /* But here we should see it. */
#endif
/* Add a few more. */ /* Add a few more. */
err = session_env_putenv (se, "X1=A value"); err = session_env_putenv (se, "X1=A value");