test1304: build and skip without netrc support

This commit is contained in:
Daniel Stenberg 2023-08-17 14:36:05 +02:00
parent acca40c9b5
commit 97a79c79a7
No known key found for this signature in database
GPG Key ID: 5CC908FDB71E12C2
2 changed files with 16 additions and 0 deletions

View File

@ -14,6 +14,7 @@ none
</server>
<features>
unittest
netrc
</features>
<name>
netrc parsing unit tests

View File

@ -25,6 +25,8 @@
#include "netrc.h"
#include "memdebug.h" /* LAST include file */
#ifndef CURL_DISABLE_NETRC
static char *login;
static char *password;
@ -181,3 +183,16 @@ UNITTEST_START
fail_unless(strncmp(login, "none", 4) == 0, "login should be 'none'");
UNITTEST_STOP
#else
static CURLcode unit_setup(void)
{
return CURLE_OK;
}
static void unit_stop(void)
{
}
UNITTEST_START
UNITTEST_STOP
#endif