Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH v3 1/5] support/testing: core testing infrastructure
Date: Thu, 23 Mar 2017 09:07:51 +0100	[thread overview]
Message-ID: <20170323090751.68c281d2@free-electrons.com> (raw)
In-Reply-To: <58d33ac6e1494_71523fd706b87604408fc@ultri3.mail>

Hello,

On Thu, 23 Mar 2017 00:02:30 -0300, Ricardo Martincoski wrote:

> 1) If I increase the value of processes in unittest.cfg to unleash the power of
> nose2, emulator fails sporadically because telnet port is fixed.

Yes, this is a known problem, and there's a TODO about this in
emulator.py:

# TODO: Most of the telnet stuff need to be replaced by stdio/pexpect to discuss
# with the qemu machine.

> 2) If I do this (not restricted to these testcases) ...
> 
> for i in $(seq 100); do \
> support/testing/run-tests -d dl1 -o output -k tests.package || break ; done
> 
> ... while performing other resource-consuming tasks on my PC, such as starting
> an unrelated build that uses all the cores, I eventually get this:
> 
> ERROR: test_run (tests.package.test_dropbear.TestDropbear)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "/tmp/testing-v3/support/testing/tests/package/test_dropbear.py", line 22, in test_run
>     self.emulator.login("testpwd")
>   File "/tmp/testing-v3/support/testing/infra/emulator.py", line 101, in login
>     self.__read_until("buildroot login:", 10)
>   File "/tmp/testing-v3/support/testing/infra/emulator.py", line 89, in __read_until
>     data = self.__tn.read_until(waitstr, timeout)
>   File "/usr/lib/python2.7/telnetlib.py", line 294, in read_until
>     return self._read_until_with_poll(match, timeout)
>   File "/usr/lib/python2.7/telnetlib.py", line 329, in _read_until_with_poll
>     self.fill_rawq()
>   File "/usr/lib/python2.7/telnetlib.py", line 576, in fill_rawq
>     buf = self.sock.recv(50)
> error: [Errno 104] Connection reset by peer

Hum, do you know why this one happens? I definitely understand that
will a qemu is running, another qemu cannot bind its telnet server on
the same TCP port, but I don't see why it would cause a "Connection
reset by peer".

Or is the logic of the test bogus, and if it doesn't manage to start
qemu, the test still continues, and it in fact connects to an already
running qemu instance from a different test, which then gets killed in
the middle ?

> Something like this patch could fix those:

It would probably be nicer to interact through stdio and pexpect, but
in the mean time, this does the job. I'll integrate that into my
series. Thanks!

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

  reply	other threads:[~2017-03-23  8:07 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-20 20:36 [Buildroot] [PATCH v3 0/5] Runtime testing infrastructure Thomas Petazzoni
2017-03-20 20:36 ` [Buildroot] [PATCH v3 1/5] support/testing: core " Thomas Petazzoni
2017-03-22  8:11   ` Thomas De Schampheleire
2017-03-23  3:02   ` Ricardo Martincoski
2017-03-23  8:07     ` Thomas Petazzoni [this message]
2017-03-24  2:19       ` Ricardo Martincoski
2017-03-26 21:54   ` Luca Ceresoli
2017-05-07 21:07   ` Luca Ceresoli
2017-05-07 21:38     ` Thomas Petazzoni
2017-03-20 20:36 ` [Buildroot] [PATCH v3 2/5] support/testing: add core tests Thomas Petazzoni
2017-03-22  8:17   ` Thomas De Schampheleire
2017-03-22  8:25     ` Thomas Petazzoni
2017-03-22  8:35       ` Thomas De Schampheleire
2017-03-20 20:36 ` [Buildroot] [PATCH v3 3/5] support/testing: add fs tests Thomas Petazzoni
2017-05-07 20:55   ` Luca Ceresoli
2017-03-20 20:36 ` [Buildroot] [PATCH v3 4/5] support/testing: add package tests Thomas Petazzoni
2017-03-22  8:26   ` Thomas De Schampheleire
2017-03-22 13:08     ` Thomas Petazzoni
2017-03-20 20:36 ` [Buildroot] [PATCH v3 5/5] support/testing: add toolchain tests Thomas Petazzoni
2017-03-26 21:53   ` Luca Ceresoli
2017-03-22  8:30 ` [Buildroot] [PATCH v3 0/5] Runtime testing infrastructure Thomas De Schampheleire
2017-05-07 20:09 ` Thomas Petazzoni
2017-05-07 20:41   ` Luca Ceresoli
2017-05-07 21:10     ` Thomas Petazzoni

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=20170323090751.68c281d2@free-electrons.com \
    --to=thomas.petazzoni@free-electrons.com \
    --cc=buildroot@busybox.net \
    /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