1
0
mirror of https://git.libssh.org/projects/libssh.git synced 2025-07-31 00:03:07 +03:00

tests: Wait longer for the server

Signed-off-by: Jakub Jelen <jjelen@redhat.com>
Reviewed-by: Norbert Pocs <npocs@redhat.com>
This commit is contained in:
Jakub Jelen
2023-04-27 15:32:25 +02:00
parent fcb6ee4031
commit f80faa89ce
3 changed files with 5 additions and 3 deletions

View File

@ -605,8 +605,8 @@ static int setup_kbdint_server(void **state)
setenv("SOCKET_WRAPPER_DEFAULT_IFACE", "21", 1);
unsetenv("PAM_WRAPPER");
/* Wait 200ms */
usleep(200 * 1000);
rc = torture_wait_for_daemon(15);
assert_int_equal(rc, 0);
tss->state = s;
tss->ss = ss;

View File

@ -905,7 +905,7 @@ static void torture_setup_create_sshd_config(void **state, bool pam)
torture_write_file(s->srv_config, sshd_config);
}
static int torture_wait_for_daemon(unsigned int seconds)
int torture_wait_for_daemon(unsigned int seconds)
{
struct ssh_timestamp start;
int rc;

View File

@ -120,6 +120,8 @@ void _torture_filter_tests(struct CMUnitTest *tests, size_t ntests);
const char *torture_server_address(int domain);
int torture_server_port(void);
int torture_wait_for_daemon(unsigned int seconds);
#ifdef SSHD_EXECUTABLE
void torture_setup_socket_dir(void **state);
void torture_setup_sshd_server(void **state, bool pam);