https://progress.opensuse.org/https://progress.opensuse.org/themes/openSUSE/favicon/favicon.ico?15829177842017-11-23T07:29:39ZopenSUSE Project Management ToolopenQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=739902017-11-23T07:29:39Zcoolocoolo@suse.com
<ul></ul><p>This is what the backend generates:</p>
<pre><code> {
"needles" : [],
"result" : "unk"
},
{
"text" : "userspace_postfix-4.txt",
"title" : "wait_serial",
"needles" : [],
"result" : "ok"
},
{
"result" : "unk",
"needles" : []
},
{
"result" : "fail",
"text" : "userspace_postfix-6.txt",
"needles" : [],
"title" : "wait_serial"
},
{
"needles" : [],
"result" : "unk"
},
{
"result" : "fail",
"needles" : [],
"title" : "wait_serial",
"text" : "userspace_postfix-8.txt"
},
</code></pre>
<p>No idea what these unk steps are</p>
openQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=739992017-11-23T07:36:21Zcoolocoolo@suse.com
<ul><li><strong>Category</strong> set to <i>Regressions/Crashes</i></li><li><strong>Target version</strong> set to <i>Ready</i></li></ul><pre><code>06:20:56.0104 12790 >>> testapi::wait_serial: (?^ui:login:\s*$): ok
06:20:56.0105 12790 <<< testapi::type_string(text='root
')
06:20:56.0109 12794 <<< consoles::virtio_screen::type_string(json_cmd_token='vzUJSetS', text='root
')
06:20:56.0112 12790 <<< testapi::wait_serial(regexp=qr/(?^ui:Password:\s*$)/, timeout=90)
</code></pre>
<p>Creates</p>
<pre><code>[
{
"text" : "# wait_serial expected: qr/(?^ui:login:\s*$)/",
"needles" : [],
"title" : "wait_serial",
"result" : "ok"
},
{
"needles" : [],
"result" : "unk"
},
{
"needles" : [],
"result" : "ok",
"title" : "wait_serial",
"text" : "# wait_serial expected: qr/(?^ui:Password:\s*$)/"
},
</code></pre> openQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=758052017-12-01T10:39:52Zdasantiagodasantiago@suse.com
<ul><li><strong>Assignee</strong> set to <i>dasantiago</i></li></ul> openQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=758082017-12-01T10:40:08Zdasantiagodasantiago@suse.com
<ul><li><strong>Status</strong> changed from <i>New</i> to <i>In Progress</i></li></ul> openQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=759492017-12-01T14:36:03Zszarate
<ul></ul><p>Assigning to current sprint (201712.1)</p>
openQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=759582017-12-01T14:36:48Zszarate
<ul><li><strong>Subject</strong> changed from <i>Same miniature for 2 steps</i> to <i>[tools] Same miniature for 2 steps</i></li></ul> openQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=759642017-12-01T14:38:07Zszarate
<ul><li><strong>Target version</strong> changed from <i>Ready</i> to <i>Current Sprint</i></li></ul> openQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=782332017-12-07T15:46:43Zdasantiagodasantiago@suse.com
<ul></ul><p>Just to update this ticket with my findings:<br>
There are three types of results:</p>
<ol>
<li>ok</li>
<li>fail</li>
<li>unk</li>
</ol>
<p>The "unk" is used when the developer wants to show the result in the webinterface, without being necessarily a failure or a success, like for example to show progress of some operation.</p>
<p>When creating the miniatures, the object is initialized as being unk.</p>
<p>The problem in this case is when is determining if the terminal is serial or not in here: <a href="https://github.com/os-autoinst/os-autoinst/blame/master/basetest.pm#L413" class="external">https://github.com/os-autoinst/os-autoinst/blame/master/basetest.pm#L413</a></p>
<p>If i remove the unless from there, everything (on that test) seems to be working fine:<br>
<a href="http://tragicbox.suse.cz/tests/296#step/userspace_postfix/1" class="external">http://tragicbox.suse.cz/tests/296#step/userspace_postfix/1</a></p>
<p>This needs more in depth analysis, as i'm afraid, this might break a lot of stuff. :-(</p>
openQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=783072017-12-07T20:31:59Zcoolocoolo@suse.com
<ul></ul><p>the problem is that there is nothing happening on that screen you keep recording. So recording a result here is just wrong. the return value is just unused - and shouldn't be there.</p>
<p>So based on your findings, I would try:</p>
<pre><code>--- a/basetest.pm
+++ b/basetest.pm
@@ -409,8 +409,8 @@ sub record_serialresult {
$string //= '';
- my $result = $self->record_testresult('unk');
unless (testapi::is_serial_terminal) {
+ my $result = $self->record_testresult('unk');
# the screenshot is not the fail, it's just for documentation
$self->_result_add_screenshot($result);
}
@@ -418,7 +418,7 @@ sub record_serialresult {
$output .= "# Result:\n";
$output .= "$string\n";
$self->record_resultfile('wait_serial', $output, result => $res);
- return $result;
+ return;
}
sub record_soft_failure_result {
@@ -429,7 +429,7 @@ sub record_soft_failure_result {
$self->_result_add_screenshot($result);
my $output = "# Soft Failure:\n$reason\n";
$self->record_resultfile('Soft Failed', $output, result => $result);
- return $result;
+ return;
}
sub register_extra_test_results {
</code></pre> openQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=783882017-12-08T09:27:59Zdasantiagodasantiago@suse.com
<ul></ul><p>coolo wrote:</p>
<blockquote>
<p>the problem is that there is nothing happening on that screen you keep recording. So recording a result here is just wrong. the return value is just unused - and shouldn't be there.</p>
</blockquote>
<p>Thanks for the clarification. </p>
openQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=785292017-12-08T18:38:07Zdasantiagodasantiago@suse.com
<ul></ul><p>coolo wrote:</p>
<blockquote>
<p>So based on your findings, I would try:</p>
</blockquote>
<p>Thanks! I guess that's it. My tests passed with the changes you wrote: <a href="http://tragicbox.suse.cz/tests/329#step/userspace_postfix/1" class="external">http://tragicbox.suse.cz/tests/329#step/userspace_postfix/1</a></p>
openQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=786332017-12-11T09:22:37Zdasantiagodasantiago@suse.com
<ul><li><strong>% Done</strong> changed from <i>0</i> to <i>100</i></li></ul> openQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=786362017-12-11T09:23:14Zdasantiagodasantiago@suse.com
<ul><li><strong>Status</strong> changed from <i>In Progress</i> to <i>Resolved</i></li></ul> openQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=829952018-01-12T14:50:33Zszarate
<ul><li><strong>Subject</strong> changed from <i>[tools] Same miniature for 2 steps</i> to <i>[tools][Sprint 201711.2] Same miniature for 2 steps</i></li></ul> openQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=830802018-01-12T17:36:42Zszarate
<ul><li><strong>Subject</strong> changed from <i>[tools][Sprint 201711.2] Same miniature for 2 steps</i> to <i>[tools][sprint 201712.2] Same miniature for 2 steps</i></li></ul> openQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=830832018-01-12T17:37:07Zszarate
<ul><li><strong>Subject</strong> changed from <i>[tools][sprint 201712.2] Same miniature for 2 steps</i> to <i>[tools][sprint 201712.1] Same miniature for 2 steps</i></li></ul> openQA Project - action #23422: [tools][sprint 201712.1] Same miniature for 2 stepshttps://progress.opensuse.org/issues/23422?journal_id=943212018-02-26T11:07:06Zszarate
<ul><li><strong>Target version</strong> changed from <i>Current Sprint</i> to <i>Done</i></li></ul>