Tarantool development patches archive
 help / color / mirror / Atom feed
From: Alexander Turenko via Tarantool-patches <tarantool-patches@dev.tarantool.org>
To: Roman Khabibov <roman.habibov@tarantool.org>
Cc: tarantool-patches@dev.tarantool.org,
	Roman Khabibov <roman.habibov1@yandex.ru>,
	Sergey Bronnikov <estetus@gmail.com>
Subject: Re: [Tarantool-patches] [PATCH] test: fix getaddrinfo test on Ubuntu 16.04
Date: Mon, 15 Mar 2021 20:48:49 +0300	[thread overview]
Message-ID: <20210315174849.ndfdv3jvnbrtb72p@tkn_work_nb> (raw)
In-Reply-To: <20201212035155.80282-1-roman.habibov@tarantool.org>

> diff --git a/test/app/gh-4138-getaddrinfo-errors.result b/test/app/gh-4138-getaddrinfo-errors.result
> index d301e3776..62b0721df 100644
> --- a/test/app/gh-4138-getaddrinfo-errors.result
> +++ b/test/app/gh-4138-getaddrinfo-errors.result
> @@ -28,7 +28,9 @@ function check_err(err)
>  -- EAI_AGAIN
>         err == 'getaddrinfo: Temporary failure in name resolution' or
>  -- EAI_AGAIN
> -       err == 'getaddrinfo: Name could not be resolved at this time' then
> +       err == 'getaddrinfo: Name could not be resolved at this time' or
> +-- EAI_NONAME
> +       err == 'getaddrinfo: No address associated with hostname' then

It is EAI_NODATA, not EAI_NONAME:

 | $ gcc -D_GNU_SOURCE -Wall -Wextra -x c <(echo -e '#include <sys/types.h>\n#include <sys/socket.h>\n#include <netdb.h>\n#include <stdio.h>\nint main() { printf("%s\\n", gai_strerror(EAI_NONAME)); return 0; }') && ./a.out; rm a.out
 | Name or service not known
 | $ gcc -D_GNU_SOURCE -Wall -Wextra -x c <(echo -e '#include <sys/types.h>\n#include <sys/socket.h>\n#include <netdb.h>\n#include <stdio.h>\nint main() { printf("%s\\n", gai_strerror(EAI_NODATA)); return 0; }') && ./a.out; rm a.out
 | No address associated with hostname

Anyway, we meet another miscompare after updating FreeBSD from 12.0 to
12.2 (see [1]), so we finally decided to don't check exact error
messages. It appears to be too fragile: it depends on OS and network
conditions both. The patch 'test: simplify check of error message from
getaddrinfo()' from [2] will handle it.

[1]: https://github.com/tarantool/tarantool-qa/issues/94
[2]: https://github.com/tarantool/tarantool/pull/5751

WBR, Alexander Turenko.

      reply	other threads:[~2021-03-15 17:48 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-12  3:51 Roman Khabibov
2021-03-15 17:48 ` Alexander Turenko via Tarantool-patches [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210315174849.ndfdv3jvnbrtb72p@tkn_work_nb \
    --to=tarantool-patches@dev.tarantool.org \
    --cc=alexander.turenko@tarantool.org \
    --cc=estetus@gmail.com \
    --cc=roman.habibov1@yandex.ru \
    --cc=roman.habibov@tarantool.org \
    --subject='Re: [Tarantool-patches] [PATCH] test: fix getaddrinfo test on Ubuntu 16.04' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox