Project

General

Profile

Actions

action #153964

open

coordination #151816: [epic] Handle openQA fixes and job group setup

[Research: 24h] Check how to not need to set YUI_REST_API=1 for each test suite without breaking old code

Added by syrianidou_sofia 3 months ago. Updated 16 days ago.

Status:
New
Priority:
Low
Assignee:
-
Target version:
-
Start date:
2024-01-19
Due date:
% Done:

0%

Estimated time:

Description

Motivation

Currently, we are distinguishing the libuyi test from the non-libyui tests by using the variable YUI_REST_API.
It would be more convenient to create a different way, based on the version of the os (=+sles15-sp3).
The challenge would be to avoid using multiple conditions in the os-autoinst-opensuse-distro repo.
This settings is tightly coupled with the yaml schedule, so it might require some research what are all the points in the code affected.

Acceptance criteria

AC1: Find strategy to avoid setting YUI_REST_API at all.

Actions #1

Updated by syrianidou_sofia 3 months ago

  • Subject changed from [Research] Check if removing YUI_REST_API var from test can work to [Research] Check if removing YUI_REST_API var from tests can work
Actions #2

Updated by JERiveraMoya 3 months ago

  • Tags set to qe-yam-mar-sprint
  • Subject changed from [Research] Check if removing YUI_REST_API var from tests can work to [Research: 24h] Check how to not need to set YUI_REST_API=1 for each test suite without breaking old code
  • Description updated (diff)
  • Status changed from New to Workable
  • Priority changed from Low to Normal
  • Parent task set to #151816
Actions #3

Updated by tinawang123 about 1 month ago

  • Status changed from Workable to In Progress
  • Assignee set to tinawang123
Actions #4

Updated by JERiveraMoya about 1 month ago

  • Tags changed from qe-yam-mar-sprint to qe-yam-apr-sprint
Actions #5

Updated by tinawang123 25 days ago

For file lib/YuiRestClient.pm:
sub is_libyui_rest_api {
set_var('YUI_REST_API', '1') unless get_var('YUI_REST_API'); <===== Add this line
return get_var('YUI_REST_API');
}
For file tests/installation/setup_libyui.pm:
#die 'Module requires YUI_REST_API variable to be set.', unless get_var('YUI_REST_API'); <=== Remove this line
set_var('YUI_REST_API', '1') unless get_var('YUI_REST_API'); <==== Add this line
VR: https://openqa.suse.de/tests/overview?arch=x86_64&flavor=Online&machine=&test=&modules=&module_re=&group_glob=¬_group_glob=&comment=&distri=sle&version=15-SP6&build=77.1&groupid=220#

If user try to import 'YuiRestClient', then we can assume user want to use libyui, set YUI_REST_API=1 by default.

Actions #6

Updated by JERiveraMoya 19 days ago

The analysis in this ticket should contain the implication of replacing function is_libyui_rest_api by a condition with the corresponding products.
Should answer questions, what happens with products not having libyui-rest-api and the ones having it, the ones having it but not using it like an offline installation in SLE 15 SP6 for example, other test suite used by other groups, what actions would they need to do.

Actions #7

Updated by tinawang123 18 days ago

Have it but not using it like an offline installation: https://openqa.suse.de/tests/13964281#

Actions #8

Updated by tinawang123 16 days ago

  • Status changed from In Progress to Resolved

Should add condition: if (is_leap('>15.2') || is_sle('>15-SP2'));
Then set_var('YUI_REST_API', '1')

Though we can add this setting to the jobs which don't need setup libyui.
But I think we'd better still use this 'YUI_REST_API=1' setting to control libyui.

Actions #9

Updated by JERiveraMoya 16 days ago ยท Edited

  • Status changed from Resolved to New
  • Assignee deleted (tinawang123)
  • Priority changed from Normal to Low

we would still be setting up the variable in the code.
Thanks for the research.
I will keep it open for someone else to investigate in the future, there is no rush with this and we could still cover more extensive analysis.

Actions #10

Updated by JERiveraMoya 16 days ago

  • Tags deleted (qe-yam-apr-sprint)
Actions

Also available in: Atom PDF