Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add DW test to verify requested resources in case of multiple local queue exists #1565

Merged
merged 1 commit into from
Jul 3, 2024

Conversation

Srihari1192
Copy link
Contributor

closes https://issues.redhat.com/browse/RHOAIENG-8559

Added test to verify Workload Metrics Requested by all projects resources when multiple local queue requesting for resources

  • refactored method Get Current CPU Usage and Get Current Memory Usage to use Get Query Value to get total requesting resource values

Wait Until Element Is Visible xpath=//*[@id="topResourceConsumingMemory-ChartLabel-title"] timeout=120
Wait Until Element Is Visible xpath=//*[@id="topResourceConsumingMemory-ChartLegend-ChartLabel-0"] timeout=120
${memory_usage} = Get Current Memory Usage ${PRJ_TITLE} Job
${memory_consuming} = Get Text xpath:(//*[@style[contains(., 'var(--pf-v5-chart-donut--label--title--Fill')]])[2]

Check warning

Code scanning / Robocop

Line is too long ({{ line_length }}/{{ allowed_length }}) Warning test

Line is too long (123/120)
${memory_requested_1} = Get Memory Requested ${PRJ_TITLE} ${LOCAL_QUEUE_NAME} Job
${memory_requested_2} = Get Memory Requested ${PRJ_TITLE} ${MULTIPLE_LOCAL_QUEUE} Job
${memory_requested} = Evaluate ${memory_requested_1} + ${memory_requested_2}
Check Requested Resources ${PRJ_TITLE} ${CPU_SHARED_QUOTA} ${MEMEORY_SHARED_QUOTA} ${cpu_requested} ${memory_requested} Job

Check warning

Code scanning / Robocop

Line is too long ({{ line_length }}/{{ allowed_length }}) Warning test

Line is too long (145/120)
Copy link
Contributor

github-actions bot commented Jun 27, 2024

Robot Results

✅ Passed ❌ Failed ⏭️ Skipped Total Pass %
501 0 0 501 100

Submit Kueue Workload
[Documentation] method for creating kueue workload
[Arguments] ${local_queue} ${project} ${cpu_requested} ${memory_requested} ${job_name_queue}
${result}= Run Process sh ${KUEUE_WORKLOADS_SETUP_FILEPATH} ${local_queue} ${project} ${cpu_requested} ${memory_requested} ${job_name_queue}

Check warning

Code scanning / Robocop

Line is too long ({{ line_length }}/{{ allowed_length }}) Warning test

Line is too long (150/120)
@Srihari1192 Srihari1192 force-pushed the RHOAIENG-8559 branch 2 times, most recently from fc514d9 to b5cdd6c Compare July 2, 2024 07:28
... shell=true
... stderr=STDOUT
Log To Console ${result.stdout}
IF ${result.rc} != 0

Check notice

Code scanning / Robocop

IF can be replaced with inline IF Note test

IF can be replaced with inline IF
... shell=true
... stderr=STDOUT
Log To Console ${result.stdout}
IF ${result.rc} != 0

Check notice

Code scanning / Robocop

'{{ block_name }}' condition can be simplified Note test

'IF' condition can be simplified
Wait For Job With Status
[Documentation] Wait for job status with job name
[Arguments] ${job_name} ${job_status} ${timeout}
Wait Until Element Is Visible //td[@class='pf-v5-c-table__td' and contains(text(), '${job_name}')]/following-sibling::td[@data-label='Status']/span/span/span[@class='pf-v5-c-label__text'and text()='${job_status}'] timeout=${timeout}

Check warning

Code scanning / Robocop

Line is too long ({{ line_length }}/{{ allowed_length }}) Warning test

Line is too long (242/120)
[Tags] RHOAIENG-8559
... Tier1 DistributedWorkloads
Submit Kueue Workload ${LOCAL_QUEUE_NAME} ${PRJ_TITLE} ${CPU_REQUESTED} ${MEMORY_REQUESTED} ${JOB_NAME_QUEUE}
${MULTIPLE_LOCAL_QUEUE} Set Variable test-multiple-local-queue

Check warning

Code scanning / Robocop

The assignment sign is not consistent within the file. Expected '{{ expected_sign }}' but got '{{ actual_sign }}' instead Warning test

The assignment sign is not consistent within the file. Expected ' =' but got '' instead
... Tier1 DistributedWorkloads
Submit Kueue Workload ${LOCAL_QUEUE_NAME} ${PRJ_TITLE} ${CPU_REQUESTED} ${MEMORY_REQUESTED} ${JOB_NAME_QUEUE}
${MULTIPLE_LOCAL_QUEUE} Set Variable test-multiple-local-queue
${MULTIPLE_JOB_NAME} Set Variable multiple-lq-job

Check warning

Code scanning / Robocop

The assignment sign is not consistent within the file. Expected '{{ expected_sign }}' but got '{{ actual_sign }}' instead Warning test

The assignment sign is not consistent within the file. Expected ' =' but got '' instead
# setup Kueue resource for the created project
Setup Kueue Resources ${PRJ_TITLE} ${CLUSTER_QUEUE_NAME} ${RESOURCE_FLAVOR_NAME} ${MULTIPLE_LOCAL_QUEUE}
# Submitting kueue batch workload
Submit Kueue Workload ${MULTIPLE_LOCAL_QUEUE} ${PRJ_TITLE} ${CPU_REQUESTED} ${MEMORY_REQUESTED} ${MULTIPLE_JOB_NAME}

Check warning

Code scanning / Robocop

Line is too long ({{ line_length }}/{{ allowed_length }}) Warning test

Line is too long (135/120)
@Srihari1192 Srihari1192 marked this pull request as ready for review July 2, 2024 11:07
@sutaakar sutaakar enabled auto-merge (rebase) July 3, 2024 06:42
@sutaakar sutaakar disabled auto-merge July 3, 2024 06:50
@sutaakar sutaakar enabled auto-merge (rebase) July 3, 2024 06:51
@sutaakar sutaakar merged commit 54607a6 into red-hat-data-services:master Jul 3, 2024
7 checks passed
@Srihari1192 Srihari1192 deleted the RHOAIENG-8559 branch October 21, 2024 07:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants