Project

General

Profile

Actions

action #96555

open

openQA does not match all areas in a needle as a whole and do not have mechanism to delay needle matching

Added by waynechen55 over 3 years ago. Updated over 3 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
Support
Target version:
Start date:
2021-08-04
Due date:
% Done:

0%

Estimated time:

Description

These test runs
https://openqa.suse.de/tests/6641391#step/boot_from_pxe/8
https://openqa.suse.de/tests/6644444#step/boot_from_pxe/8
matches the following needle 100%:
boot_from_pxe-qa-net-grub-boot-linux-20210803.json

boot_from_pxe-qa-net-grub-boot-linux-20210803.png
The needle has 4 areas to be matched.
But it seems that the fourth or the last area has partial same content compared with the third area(a subset of the third area).
So the needle matching just treat the fourth area as part of the third area instead of matching it at the required location,because the forth area do not appear at the same time with the third area. It will appear after "kernel" downloading finishes.

This mechanism leads to test failure, because the subsequent commands can only be typed in after all 4 areas in boot_from_pxe-qa-net-grub-boot-linux-20210803 are matched at their preferred location instead of matching area4 at area3.

Workaround like some sort of delay can be applied before typing subsequent commands or even check_screen, but I do think this is perfect solution to this problem.

Any better solution to this problem ? Any argument can be used to solve the problem ? I need to match the "grub>" prompt multiple times but at different locations in one needle, and one "grub>" prompt appears on the screen later than the immediate last one.

I think this is just another way to capture and match needle and can be very useful to facilitate test run. So whether the needle matching mechanism can be enhanced in certain ways, for example:
1). An option to match all areas in one needle as a whole instead of searching one by one.
2). Introduce "delay" as additional argument in check_screen and assert_screen to delay the start of needle matching.

Actions

Also available in: Atom PDF