Skip to content

Ensure cpu/clocktest does not run on the s390x architecture (BugFix)#1704

Merged
Hook25 merged 1 commit intocanonical:mainfrom
pesader:main
Jan 31, 2025
Merged

Ensure cpu/clocktest does not run on the s390x architecture (BugFix)#1704
Hook25 merged 1 commit intocanonical:mainfrom
pesader:main

Conversation

@pesader
Copy link
Copy Markdown
Contributor

@pesader pesader commented Jan 31, 2025

Description

The cpu/clocktest test doesn't work on s390x due to issues with sched_setaffinity (as discussed in issue #422), so make sure this test doesn't run on this architecture. To do that, add a requires to the cpu/clocktest so it doesn't fulfill its requirements if the detected CPU architecture is "s390x".

Resolved issues

Tests

I haven't written any Python code for this contribution, so I don't think the test coverage has changed. Still, I ran coverage and attached its HTML coverage report below.

htmlcov.zip

However, I have manually tested this change by running checkbox and making sure cpu/clocktest still runs on my x86 laptop and it did (the test description is "Tests the CPU for clock jitter"):

image

I don't have an IBM mainframe at hand 😅, so I tried changing "s390x" to "x86_64" to see if the test didn't run on my laptop and it didn't:

image

I make myself available for further changes and explanations. Thank you for reviewing this!

The cpu/clocktest test doesn't work on s390x due to issues with
sched_setaffinity, so skip this test on this architecture.

Fixes: canonical#422
Copy link
Copy Markdown
Collaborator

@Hook25 Hook25 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1, note that this works only if the platforms are uniform due to how negations work in resource expressions, either way, I think we can make this assumption

@codecov
Copy link
Copy Markdown

codecov bot commented Jan 31, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 49.01%. Comparing base (4b89d45) to head (cd004ba).
Report is 130 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1704   +/-   ##
=======================================
  Coverage   49.01%   49.01%           
=======================================
  Files         372      372           
  Lines       40348    40348           
  Branches     6817     6817           
=======================================
  Hits        19777    19777           
  Misses      19849    19849           
  Partials      722      722           
Flag Coverage Δ
provider-base ∅ <ø> (∅)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@Hook25 Hook25 merged commit decfce9 into canonical:main Jan 31, 2025
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.

2 participants