From: Karel Zak <kzak@redhat.com>
To: Rainer Gerhards <rgerhards@gmail.com>
Cc: Sami Kerola <kerolasa@iki.fi>, util-linux@vger.kernel.org
Subject: Re: [PATCH 0/8] pull: logger: add tests and fix couple issues
Date: Mon, 16 Mar 2015 13:06:31 +0100 [thread overview]
Message-ID: <20150316120631.GL28925@ws.net.home> (raw)
In-Reply-To: <CAP-up9AJwjQU8Mq5fT0wYZgv2noqz845EtVt-CiYjN=F0J8R5A@mail.gmail.com>
On Mon, Mar 16, 2015 at 12:28:19PM +0100, Rainer Gerhards wrote:
> On Sun, Mar 15, 2015 at 1:54 PM, Sami Kerola <kerolasa@iki.fi> wrote:
> > Hello,
> >
> > Coverage of these tests is not magnificent. None of the communications
> > to external systems using tcp, udp, or to journald are tested, but at
> > least some aspects of the logger(1) functionality gets to be checked -
> > that is message formats and input validation.
>
>
> ah! excellent. I'll also have a look to understand the nature of how
> tests work for util-linux. Regarding tcp and udp: I guess a simple way
> would be to use netcat? Or is that considered bad practice for
> util-linux (as versions may differ and may interfere with test
> results?
We have no any strict policy for tests, it's fine to check all
necessary environment and versions and skip (ts_skip function) all
the test if necessary.
We have two basic modes:
* "non-root" (make check) - this is usually for simple tests where you
don't need root permissions and where is it safe to call the test
on arbitrary machine (to make it usable for example from spec
files on build machines, etc.)
* "root" - this is for dangerous tests you never want to call on
production system, it's never executed by build system and you
have to manually "cd tests; ./run.sh". This is for example for
mount(8), some fdisk tests etc. These tests are for developers
only.
Note I have just committed a new --no-act logger command line option
to make it possible to check messages formatting without spam in
system logs, for example:
$ logger --no-act --stderr --rfc5424 "This is message"
I guess we can use it for messages formatting tests (as the tests
suggested by Sami).
Karel
--
Karel Zak <kzak@redhat.com>
http://karelzak.blogspot.com
next prev parent reply other threads:[~2015-03-16 12:06 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-15 12:54 [PATCH 0/8] pull: logger: add tests and fix couple issues Sami Kerola
2015-03-15 12:54 ` [PATCH 1/8] logger: tidy few indentation issues Sami Kerola
2015-03-16 10:52 ` Karel Zak
2015-03-16 11:22 ` Rainer Gerhards
2015-03-16 11:50 ` Karel Zak
2015-03-15 12:54 ` [PATCH 2/8] logger: check xgethostname() return value Sami Kerola
2015-03-16 10:53 ` Karel Zak
2015-03-15 12:54 ` [PATCH 3/8] tests: add test_logger helper command Sami Kerola
2015-03-16 10:57 ` Karel Zak
2015-03-16 13:19 ` Karel Zak
2015-03-15 12:54 ` [PATCH 4/8] tests: add logger(1) command line options tests Sami Kerola
2015-03-15 12:54 ` [PATCH 5/8] logger: fix rfc5424 format crash Sami Kerola
2015-03-16 10:49 ` Karel Zak
2015-03-16 10:55 ` Rainer Gerhards
2015-03-16 11:13 ` Karel Zak
2015-03-16 10:57 ` Rainer Gerhards
2015-03-15 12:54 ` [PATCH 6/8] tests: add logger(1) message format tests Sami Kerola
2015-03-15 12:54 ` [PATCH 7/8] logger: use errx() when checking user input Sami Kerola
2015-03-16 10:54 ` Karel Zak
2015-03-15 12:54 ` [PATCH 8/8] tests: add logger(1) error condition tests Sami Kerola
2015-03-16 11:28 ` [PATCH 0/8] pull: logger: add tests and fix couple issues Rainer Gerhards
2015-03-16 12:06 ` Karel Zak [this message]
2015-03-16 23:55 ` Sami Kerola
2015-03-17 9:06 ` Karel Zak
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=20150316120631.GL28925@ws.net.home \
--to=kzak@redhat.com \
--cc=kerolasa@iki.fi \
--cc=rgerhards@gmail.com \
--cc=util-linux@vger.kernel.org \
/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