-
Notifications
You must be signed in to change notification settings - Fork 46
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
fix(RHINENG-12778): Add tooltip for locked OS versions #2197
base: master
Are you sure you want to change the base?
Conversation
Referenced Jiras: |
If someone has a clever way to test this, I'd love to hear it. Considering we can't render the |
This PR notifies a user if a system's OS version is locked. When version locking is enabled for a system i.e. a system's OS is tied to a release version, that can affect the count of applicable and installable errata\advisories. The backend now passes a key from the `/systems` api endpoint called `rhsm_lock` and the value is the locked version number. With this PR, we check on the Systems table as well as the CVEs -> CVEDetails tables. When the `rhsm_lock` parameter has a value, we include an icon with a tooltip that tells the user "Your RHEL version is locked..." and at which version it is locked at.
ff433d3
to
40bcfbf
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #2197 +/- ##
==========================================
+ Coverage 67.14% 69.10% +1.96%
==========================================
Files 130 131 +1
Lines 3476 3483 +7
Branches 1106 1106
==========================================
+ Hits 2334 2407 +73
+ Misses 1142 1076 -66 ☔ View full report in Codecov by Sentry. |
beforeEach(() => { | ||
useSelector.mockImplementation(callback => { | ||
return callback({ SystemsPageStore: initialState, entities: entitiesInitialState }); | ||
}); | ||
useDispatch.mockReturnValue(jest.fn()); | ||
}); | ||
|
||
it.skip('should call fetchData function', () => { | ||
afterEach(() => { | ||
useSelector.mockClear(); | ||
store.clearActions(); | ||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It might be better to put them within the describe
to ensure the effects of these callbacks don't leak into other tests.
We might be able to test tooltips with the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested and (i) + Tooltip show up as expected. Thank you @johnsonm325!
@bastilian my issues is that I can't render the InventoryTable in tests. And since the tooltip is linked to the columns, I'm not sure how to get this tooltip to render. |
This PR notifies a user if a system's OS version is locked. When version locking is enabled for a system i.e. a system's OS is tied to a release version, that can affect the count of applicable and installable errata\advisories.
The backend now passes a key from the
/systems
api endpoint calledrhsm_lock
and the value is the locked version number. With this PR, we check on the Systems table as well as the CVEs -> CVEDetails tables. When therhsm_lock
parameter has a value, we include an icon with a tooltip that tells the user "Your RHEL version is locked..." and at which version it is locked at.