Skip to content

Fixes #30288 - replace CPU/Cores/socket input to react comp - #7865

Merged
ezr-ondrej merged 1 commit into
theforeman:developfrom
yifatmakias:30288
Apr 8, 2021
Merged

ezr-ondrej merged 1 commit into
theforeman:developfrom
yifatmakias:30288

Conversation

@yifatmakias

Copy link
Copy Markdown
Contributor

No description provided.

Comment thread webpack/assets/javascripts/react_app/components/CPUCoresInput/cpuCoresInput.scss Outdated
Comment thread webpack/assets/javascripts/react_app/components/CPUCoresInput/cpuCoresInput.scss Outdated
@theforeman-bot

Copy link
Copy Markdown
Member

Issues: #30288

Comment thread webpack/assets/javascripts/react_app/components/CPUCoresInput/cpuCoresInput.scss Outdated

@MariaAga MariaAga left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks Yifat! Snapshots should be replaced and can you add tests for the warning and error states of the component?
Also I think there shouldn't be space between the warning and the cpu input, and instead there should be space between the warning and the next input, you can maybe add a class to the cpu input and add/remove margins

Comment thread webpack/assets/javascripts/react_app/components/CPUCoresInput/cpuCoresInput.scss Outdated
Comment thread webpack/assets/javascripts/react_app/components/common/forms/NumericInput.js Outdated
Comment thread webpack/assets/javascripts/react_app/components/CPUCoresInput/CPUCoresInput.js Outdated
Comment thread webpack/assets/javascripts/react_app/components/CPUCoresInput/CPUCoresInput.js Outdated

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Also I think for the warnings it makes sense to take the rest of the Row so can you change 4 to 10?

@yifatmakias

Copy link
Copy Markdown
Contributor Author

@MariaAga Thanks for the review.
I fixed the tests and all the comments.
I still need to add more tests and to fix the double space between the input to the alert message.

@coveralls

coveralls commented Jul 29, 2020 •

Copy link
Copy Markdown

Coverage Status

Coverage increased (+0.02%) to 73.85% when pulling 4855efb456fcb1448fdb6b22f0d6952d760f0e94 on yifatmakias:30288 into cbf3a1f on theforeman:develop.

@yifatmakias
yifatmakias force-pushed the 30288 branch 2 times, most recently from a8a221c to 3979be4 Compare August 2, 2020 07:55
@amirfefer

Copy link
Copy Markdown
Member

foreman tests failures look related

@yifatmakias yifatmakias closed this Aug 3, 2020
@yifatmakias yifatmakias reopened this Aug 3, 2020
@yifatmakias

Copy link
Copy Markdown
Contributor Author

@amirfefer Yes I know, I am working on fixing it.

@yifatmakias
yifatmakias force-pushed the 30288 branch 3 times, most recently from 693f156 to 50329ba Compare August 4, 2020 07:56

@MariaAga MariaAga left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks like the tests are working now 🎉

Comment on lines 19 to 14

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Can you merge this into 1 object?
fixtures ={ 'should..default...':{}, 'should..warning...':{}, 'should..error...':{}}

@yifatmakias

Copy link
Copy Markdown
Contributor Author

[test katello]

@yifatmakias

Copy link
Copy Markdown
Contributor Author

[test katello]

@yifatmakias

Copy link
Copy Markdown
Contributor Author

[test foreman]

xprazak2
xprazak2 previously approved these changes Jan 27, 2021

@xprazak2 xprazak2 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Works well on libvirt, I haven't tested ovirt or vmware.

@shiramax shiramax left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks @yifatmakias

I see some strange behavior here, every time I increase the socket, the cores also increase and vice versa,
it shouldn't be like that, the cores and socket are completely different attributes.

@yifatmakias

Copy link
Copy Markdown
Contributor Author

@shiramax You are definitely right I will figure out the problem and fix this.
Thanks!

@yifatmakias

Copy link
Copy Markdown
Contributor Author

[test katello]

@ezr-ondrej ezr-ondrej left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This works and code looks good.
Thanks a lot, loving this ❤️ 👍

@ezr-ondrej

Copy link
Copy Markdown
Member

@MariaAga, @shiramax were your concerns addressed?

@shiramax

shiramax commented Apr 8, 2021

Copy link
Copy Markdown
Contributor

@ezr-ondrej yes. thanks

@ezr-ondrej
ezr-ondrej dismissed MariaAga’s stale review April 8, 2021 11:28

I believe all concerns were addressed.

@ezr-ondrej
ezr-ondrej merged commit 22fa163 into theforeman:develop Apr 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants