<feed xmlns='http://www.w3.org/2005/Atom'>
<title>buildroot/support/testing/infra/emulator.py, branch 2018.02</title>
<subtitle>OpenPOWER buildroot sources</subtitle>
<id>https://git.raptorcs.com/git/buildroot/atom?h=2018.02</id>
<link rel='self' href='https://git.raptorcs.com/git/buildroot/atom?h=2018.02'/>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/'/>
<updated>2017-08-10T08:08:06+00:00</updated>
<entry>
<title>support/testing: allow to use a multiplier for timeouts</title>
<updated>2017-08-10T08:08:06+00:00</updated>
<author>
<name>Ricardo Martincoski</name>
<email>ricardo.martincoski@gmail.com</email>
</author>
<published>2017-08-05T02:05:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=6e45e33f27d5ae6fa0ab5aad3f032d886a886037'/>
<id>urn:sha1:6e45e33f27d5ae6fa0ab5aad3f032d886a886037</id>
<content type='text'>
Add a parameter to run-tests to act as a multiplier for all timeouts of
emulator.
It can be used to avoid sporadic failures on slow host machines as well
in elastic runners on the cloud.

Cc: Arnout Vandecappelle &lt;arnout@mind.be&gt;
Cc: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
Signed-off-by: Ricardo Martincoski &lt;ricardo.martincoski@gmail.com&gt;
[Arnout: rename multiplier to timeout_multiplier everywhere]
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) &lt;arnout@mind.be&gt;
</content>
</entry>
<entry>
<title>testing/infra/emulator: remove qemu warnings about audio</title>
<updated>2017-07-31T19:26:06+00:00</updated>
<author>
<name>Ricardo Martincoski</name>
<email>ricardo.martincoski@gmail.com</email>
</author>
<published>2017-07-30T04:49:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=d8ab6b2b54574a5e5d5818ca3e816d2afd159ad0'/>
<id>urn:sha1:d8ab6b2b54574a5e5d5818ca3e816d2afd159ad0</id>
<content type='text'>
The default audio backend for qemu is configured at compile time. It
generates annoying warning messages to qemu's stderr when running our
tests, like these:
pulseaudio: set_sink_input_volume() failed
pulseaudio: Reason: Invalid argument
pulseaudio: set_sink_input_mute() failed
pulseaudio: Reason: Invalid argument

Explicitly set the audio backend to "none" at runtime to remove those
messages from our logs. There is no command line argument for this, so
use an environment variable when starting qemu.

Signed-off-by: Ricardo Martincoski &lt;ricardo.martincoski@gmail.com&gt;
Signed-off-by: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
</content>
</entry>
<entry>
<title>testing/infra/emulator: allow to specify pexpect timeout</title>
<updated>2017-07-22T20:37:06+00:00</updated>
<author>
<name>Andrey Smirnov</name>
<email>andrew.smirnov@gmail.com</email>
</author>
<published>2017-07-12T02:40:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=255b8ab406cf6ce114b4d2c2e2c0dba6e4402f38'/>
<id>urn:sha1:255b8ab406cf6ce114b4d2c2e2c0dba6e4402f38</id>
<content type='text'>
Some commands take more than 5 seconds to complete under QEMU, so add
provisions to allow individual unit-test to specify different duration
to avoid false negative test failures.

Signed-off-by: Andrey Smirnov &lt;andrew.smirnov@gmail.com&gt;
Reviewed-by: Ricardo Martincoski &lt;ricardo.martincoski@gmail.com&gt;
Tested-by: Ricardo Martincoski &lt;ricardo.martincoski@gmail.com&gt;
Signed-off-by: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
</content>
</entry>
<entry>
<title>support/testing: large timeout for login prompt</title>
<updated>2017-07-01T14:05:14+00:00</updated>
<author>
<name>Ricardo Martincoski</name>
<email>ricardo.martincoski@gmail.com</email>
</author>
<published>2017-06-29T02:45:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=9bb306bd6411071cd07529923b825627502c794d'/>
<id>urn:sha1:9bb306bd6411071cd07529923b825627502c794d</id>
<content type='text'>
When running multiple instances of emulator in parallel, the login
prompt can take some time to appear.

Use a large timeout when waiting for the prompt to avoid random
failures.

Signed-off-by: Ricardo Martincoski &lt;ricardo.martincoski@gmail.com&gt;
Signed-off-by: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
</content>
</entry>
<entry>
<title>support/testing: fix code style in emulator</title>
<updated>2017-07-01T14:05:14+00:00</updated>
<author>
<name>Ricardo Martincoski</name>
<email>ricardo.martincoski@gmail.com</email>
</author>
<published>2017-06-29T02:45:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=abe64676d58c6099f363cd6b2199d7804a9bf953'/>
<id>urn:sha1:abe64676d58c6099f363cd6b2199d7804a9bf953</id>
<content type='text'>
Remove unused import.
Use 2 empty lines before a class.

Signed-off-by: Ricardo Martincoski &lt;ricardo.martincoski@gmail.com&gt;
Signed-off-by: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
</content>
</entry>
<entry>
<title>support/testing: use pexpect.expect directly</title>
<updated>2017-07-01T14:05:14+00:00</updated>
<author>
<name>Ricardo Martincoski</name>
<email>ricardo.martincoski@gmail.com</email>
</author>
<published>2017-06-29T02:45:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=4a622fe4b6aeca8758156c24e89713d214fa2aa6'/>
<id>urn:sha1:4a622fe4b6aeca8758156c24e89713d214fa2aa6</id>
<content type='text'>
When using pexpect there is no need for a helper function. Just use
expect() directly everywhere.

Signed-off-by: Ricardo Martincoski &lt;ricardo.martincoski@gmail.com&gt;
Signed-off-by: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
</content>
</entry>
<entry>
<title>support/testing: use pexpect.sendline directly</title>
<updated>2017-07-01T14:05:14+00:00</updated>
<author>
<name>Ricardo Martincoski</name>
<email>ricardo.martincoski@gmail.com</email>
</author>
<published>2017-06-29T02:45:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=77b4b948fc0309a1cf3eef55f44bec260319e5f8'/>
<id>urn:sha1:77b4b948fc0309a1cf3eef55f44bec260319e5f8</id>
<content type='text'>
When using pexpect there is no need for a helper function. Just use
sendline() directly everywhere.

Signed-off-by: Ricardo Martincoski &lt;ricardo.martincoski@gmail.com&gt;
Signed-off-by: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
</content>
</entry>
<entry>
<title>support/testing: let pexpect write stdout to log</title>
<updated>2017-07-01T14:05:14+00:00</updated>
<author>
<name>Ricardo Martincoski</name>
<email>ricardo.martincoski@gmail.com</email>
</author>
<published>2017-06-29T02:45:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=e664c5f71c9614b991b13225809772eaea4a3dc5'/>
<id>urn:sha1:e664c5f71c9614b991b13225809772eaea4a3dc5</id>
<content type='text'>
When the parameter logfile is passed to spawn(), pexpect sends both
stdin and stdout to the logfile and it creates a double echo effect.

One way to avoid the double echo in the logfile would be to disable the
echo on the terminal just after login ("stty -echo"), but double echo of
user and password would remain.

Instead of that, send only the stdout to the logfile using the
logfile_read property.

Signed-off-by: Ricardo Martincoski &lt;ricardo.martincoski@gmail.com&gt;
Signed-off-by: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
</content>
</entry>
<entry>
<title>support/testing: use qemu stdio in emulator</title>
<updated>2017-07-01T14:05:14+00:00</updated>
<author>
<name>Ricardo Martincoski</name>
<email>ricardo.martincoski@gmail.com</email>
</author>
<published>2017-06-29T02:45:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=8ebc2278067eb99a25ce3098867f1f613ab50c7f'/>
<id>urn:sha1:8ebc2278067eb99a25ce3098867f1f613ab50c7f</id>
<content type='text'>
Instead of redirecting qemu serial to telnet, redirect it to stdio.

It allows to run testcases in parallel without random failing caused by
two emulators trying to use the same telnet port (1234).

'qemu -serial stdio' returns some extra &lt;CR&gt; characters, so remove them
from the log.

Signed-off-by: Ricardo Martincoski &lt;ricardo.martincoski@gmail.com&gt;
Signed-off-by: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
</content>
</entry>
<entry>
<title>support/testing: use pexpect in emulator</title>
<updated>2017-07-01T14:05:14+00:00</updated>
<author>
<name>Ricardo Martincoski</name>
<email>ricardo.martincoski@gmail.com</email>
</author>
<published>2017-06-29T02:45:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/buildroot/commit/?id=eb0fab80f6a89df903330a0f4f51623a1abed731'/>
<id>urn:sha1:eb0fab80f6a89df903330a0f4f51623a1abed731</id>
<content type='text'>
Replace subprocess + telnetlib with pexpect.

Use the telnet installed on the host machine instead of telnetlib, while
the serial from qemu is not yet redirected to stdio.

Signed-off-by: Ricardo Martincoski &lt;ricardo.martincoski@gmail.com&gt;
Signed-off-by: Thomas Petazzoni &lt;thomas.petazzoni@free-electrons.com&gt;
</content>
</entry>
</feed>
