Project

General

Profile

action #107749

Send the correct number of keys in send_key_until_needlematch

Added by geor 4 months ago. Updated 4 months ago.

Status:
Workable
Priority:
Normal
Assignee:
-
Target version:
Start date:
2022-03-01
Due date:
% Done:

0%

Estimated time:

Description

Motivation

Function send_key_until_needlematch, instead of sending the specified key n times, passed via argument, sends the key n+1 times before failing.
This is an issue for some scenarios, for example if an even number of keypresses is required, as is the case of maximizing and unmaximizing a window, by sending an even number of alt-f10.

Scope

Affects all testsuites that call testapi's send_key_until_needlematch.

Acceptance criteria

ΑC1: Modify send_key_until_needlematch so that key is sent the exact amount of times specified in the argument, before failing.
AC2: Make sure that testsuites that use send_key_until_needlematch are not affected

Suggestion

Change the send_key_until_needlematch so that if (!$counter--) becomes if (!--$counter) so that the assert_screen command is executed when $counter has become 0, not -1.

History

#2 Updated by JERiveraMoya 4 months ago

  • Tags deleted (qe-yast-refinement)
  • Status changed from New to Workable

Also available in: Atom PDF