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

Update Rubocop, and add minitest reporters #122

Merged
merged 19 commits into from
Jul 12, 2023

Conversation

archanaserver
Copy link
Contributor

@archanaserver archanaserver commented Jun 1, 2023

cherry-picked from f91f0e2

Based on: #121

@ehelms
Copy link
Member

ehelms commented Jun 2, 2023

Looks like you will need to address the Rubocop error before we can see if the tests pass.

@archanaserver
Copy link
Contributor Author

Looks like you will need to address the Rubocop error before we can see if the tests pass.

@ehelms rubocop error is fixed now!

@archanaserver
Copy link
Contributor Author

@ehelms yes this worked with this simpler way. Thanks!

Also now it just need rubocop version update, which needs some offenses to resolve to satisfy fully, here I have already committed this changes 1dabb8c#diff-d09ea66f8227784ff4393d88a19836f321c915ae10031d16c93d67e6283ab55fR5-R11

@ehelms
Copy link
Member

ehelms commented Jun 13, 2023

@ehelms yes this worked with this simpler way. Thanks!

Also now it just need rubocop version update, which needs some offenses to resolve to satisfy fully, here I have already committed this changes 1dabb8c#diff-d09ea66f8227784ff4393d88a19836f321c915ae10031d16c93d67e6283ab55fR5-R11

I am thinking you will need to add that Rubocop commit as commit in this PR so that the tests pass fully.

@ehelms
Copy link
Member

ehelms commented Jun 21, 2023

[test smart_proxy_dynflow]

@ehelms
Copy link
Member

ehelms commented Jun 21, 2023

Let's at least update Ruby 3.1 on Jenkins to latest 3.1.4 to match what Github Actions is using: theforeman/foreman-infra#1850

@ehelms
Copy link
Member

ehelms commented Jun 22, 2023

[test smart_proxy_dynflow]

Copy link
Member

@ekohl ekohl left a comment

Choose a reason for hiding this comment

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

This PR now contains the update to Ruby 3. I'd try to keep that out of this PR and keep it minimal.

A while back I submitted #104 which contains some work to update RuboCop and only utilizes the existing (passing) GH Actions. I'd recommend starting with that. In the next PRs you can add the jenkins:unit task and then change the Ruby version matrix.

I'll also admit I really like the GH annotations for failed RuboCop rules, which you can see in my PR.

@ehelms
Copy link
Member

ehelms commented Jul 7, 2023

The failure is on 3.1, so I think if you do as suggested and pull out fb5cbf6 from the set of commits, that this will focus this PR on the Rubocop updates + changes to get tests running and passing. Then a dedicated Ruby 3 PR can be opened with a smaller diff and allow debugging the test failure easier.

@archanaserver
Copy link
Contributor Author

archanaserver commented Jul 10, 2023

@ehelms @ekohl I've moved Ruby changes from this PR to #123.
Also about the jenkins failure, it is something related to timeout coming from here https://github.com/theforeman/smart_proxy_dynflow/blob/master/test/process_manager_test.rb#L109-L111. I tried debugging looking at Dynflow gem version and some other ways to but that didn't worked. I'm not sure what I'm missing here and doing wrong.

@ehelms
Copy link
Member

ehelms commented Jul 10, 2023

The branch that is failing is Ruby 3.1, maybe we need to just accept an dignore this failure for now and try to address it here? #123

@ekohl what do you think about that strategy? Our CI is already updated to test Ruby 3, but the project itself has not been updated, so it's a bit of a chicken-egg

@ekohl
Copy link
Member

ekohl commented Jul 10, 2023

@ehelms I'm not sure where I said it, but if it's only about Ruby 3.1 then it's not a blocker to merging it.

@ehelms ehelms changed the title define jenkins:unit rake task Update Rubocop, and add minitest reporters Jul 12, 2023
@ehelms ehelms merged commit 2df94e5 into theforeman:master Jul 12, 2023
3 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Archived in project
Development

Successfully merging this pull request may close these issues.

4 participants