From: Petr Vorel <pvorel@suse.cz>
To: ltp@lists.linux.it
Subject: [LTP] [PATCH 4/4] libs: sigwait: Get rid of REPORT_SUCCESS() macro
Date: Fri, 24 Jul 2020 15:35:24 +0200 [thread overview]
Message-ID: <20200724133524.GA31265@dell5510> (raw)
In-Reply-To: <20200724123235.GA3539@yuki.lan>
Hi,
...
> > TEST(sigwaitinfo(&sigs, &si, NULL));
> > - REPORT_SUCCESS(-1, EINTR);
> > + if (TST_RET == -1) {
> > + if (TST_ERR == EINTR)
> > + tst_res(TPASS, "%s: Test passed", __func__);
> > + else
> > + tst_res(TFAIL | TTERRNO, "%s: Unexpected failure", __func__);
> Can we please make the messages a bit more user friendly?
> - the tst_res() already prints line and filename the __func__ is a bit
> redundant
> - it also prints PASS/FAIL so we can omit the "Test passed" we can print
> something that describes the testcase instead e.g.
> "Wait interrupted by a signal"
> - also in the "Unexpected failure" case we should print which error we
> expected with someting as: tst_res(TFAIL | TTERRNO, "Expected to return EINTER, got");
+1, sorry for overlooking it.
Kind regards,
Petr
next prev parent reply other threads:[~2020-07-24 13:35 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-23 13:42 [LTP] [PATCH 1/4] libs: sigwait: Use SAFE_FORK() Viresh Kumar
2020-07-23 13:42 ` [LTP] [PATCH 2/4] libs: sigwait: Add SAFE_SIG*() macros Viresh Kumar
2020-07-24 5:51 ` Petr Vorel
2020-07-24 8:43 ` Cyril Hrubis
2020-07-23 13:42 ` [LTP] [PATCH 3/4] libs: sigwait: Remove alarm() from setup() and cleanup() Viresh Kumar
2020-07-24 5:52 ` Petr Vorel
2020-07-24 8:44 ` Cyril Hrubis
2020-07-23 13:42 ` [LTP] [PATCH 4/4] libs: sigwait: Get rid of REPORT_SUCCESS() macro Viresh Kumar
2020-07-24 5:58 ` Petr Vorel
2020-07-24 10:34 ` Viresh Kumar
2020-07-24 12:20 ` Cyril Hrubis
2020-07-24 13:37 ` Petr Vorel
2020-07-24 12:32 ` Cyril Hrubis
2020-07-24 13:35 ` Petr Vorel [this message]
2020-07-24 5:49 ` [LTP] [PATCH 1/4] libs: sigwait: Use SAFE_FORK() Petr Vorel
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=20200724133524.GA31265@dell5510 \
--to=pvorel@suse.cz \
--cc=ltp@lists.linux.it \
/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
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox