Skip to content

Refactor Operator test packages - #12359

Merged
abstractj merged 1 commit into
keycloak:mainfrom
vmuzikar:refine-tests
Jun 13, 2022
Merged

abstractj merged 1 commit into
keycloak:mainfrom
vmuzikar:refine-tests

Conversation

@vmuzikar

@vmuzikar vmuzikar commented Jun 6, 2022 •

Copy link
Copy Markdown
Contributor

Closes #12353

The change from failsafe to surefire was motivated by the test classes renaming. It was also a good opportunity to align with rest of the KC project and use surefire.

Comment thread pom.xml Outdated

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Upgrading surefire to fix SUREFIRE-1926.

Comment thread pom.xml Outdated

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

This workaround should be no longer needed with the newer surefire version: SUREFIRE-1983.

@vmuzikar
vmuzikar force-pushed the refine-tests branch 2 times, most recently from f6fb64a to 070c956 Compare June 7, 2022 13:03
Comment thread .github/workflows/ci.yml Outdated

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

This is to make surefire happy. Without this change it tries to run **.cluster.** tests inside all integration-arquillian modules, even those without tests, so it fails.

@vmuzikar

vmuzikar commented Jun 7, 2022

Copy link
Copy Markdown
Contributor Author

The failed tests seem to be unrelated to this change.

@vmuzikar
vmuzikar requested review from DGuhr, andreaTP and pedroigor June 7, 2022 15:25
@andreaTP

andreaTP commented Jun 8, 2022

Copy link
Copy Markdown
Contributor

Thanks for taking care of this @vmuzikar .

I have no problem with the "Refactor Operator test packages" applied in this PR.
I'm not sure if the surefire bump is desirable.

Would you mind separating in 2 PRs:

  • refactoring the test classes names/packages -> this will be approved in no time and merged
  • update the surefire plugin

@vmuzikar

vmuzikar commented Jun 8, 2022

Copy link
Copy Markdown
Contributor Author

@andreaTP Thanks for your review!

The surefire version bump was motivated mainly to provide the same UX as the previous failsafe. Surafire had a bug that caused the log to be "slow". I can open a separate PR for it, if you want.

@andreaTP

andreaTP commented Jun 8, 2022

Copy link
Copy Markdown
Contributor

@vmuzikar don't take me wrong, I'm ok with it, but, since it's a change that affects the entire project I feel like it needs different reviewers.

DGuhr
DGuhr previously approved these changes Jun 8, 2022

@DGuhr DGuhr 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.

imo it is ok to sneak this bump in here. I checked the tests out locally and ran (parts of) the arq testsuite and the whole quarkus testsuite, no problem there. as the testsuite is green: works for me. but no hard opinions, could also be split up into two. 🤷‍♂️

@vmuzikar
vmuzikar requested a review from hmlnarik June 8, 2022 14:01
andreaTP
andreaTP previously approved these changes Jun 9, 2022

@andreaTP andreaTP 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.

Not fussy about separating in 2 PRs. LGTM

Comment thread operator/app/pom.xml Outdated

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.

For future reference, I don't have any better proposal now.
But this approach to running all of the tests in the verify phase compromises the speed of running plain unit tests and we might want to re-iterate in the future.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yes, and not only unit tests unfortunately. Even the integration tests could be run at test phase. Basically, we need verify only when testing in the "remote" mode (operator deployed in the cluster). Maybe we could introduce some special profile for this scenario.

miquelsi
miquelsi previously approved these changes Jun 9, 2022
@vmuzikar
vmuzikar requested a review from abstractj June 9, 2022 14:37
@abstractj

Copy link
Copy Markdown
Contributor

@vmuzikar I'm fine about merging it based on the review here. But we need to rebase/resolve conflicts.

@vmuzikar
vmuzikar dismissed stale reviews from miquelsi, andreaTP, and DGuhr via e228c1c June 9, 2022 15:49
@vmuzikar

vmuzikar commented Jun 9, 2022

Copy link
Copy Markdown
Contributor Author

@abstractj Sorry, I was too quick. 🙂 Rebased, let's wait for the CI...

@abstractj

Copy link
Copy Markdown
Contributor

@vmuzikar I still see the conflicts, could you please take a look?

@DGuhr DGuhr 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.

assuming the tests get green, LGTM (again) ;)

@vmuzikar

Copy link
Copy Markdown
Contributor Author

@abstractj Sorry, another conflict was caused by merging #12404. Should be good to go now.

@abstractj

Copy link
Copy Markdown
Contributor

@vmuzikar could you please check the test failures?

@vmuzikar

Copy link
Copy Markdown
Contributor Author

@abstractj I believe the test errors are unrelated to these changes.

@DGuhr DGuhr 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.

PR still LGTM.

The test failures should be unrelated. For the undertow-map failure, I added it here: #12445 (pls help me out there in the future ;) )

For the quarkus group 3 failure (https://github.com/keycloak/keycloak/runs/6835918820?check_suite_focus=true#step:8:2059 ) : Should also be unrelated. I've seen this exact test fail pretty often the last days, but not yet in the quarkus testsuite. See also the other comments in #12445, they show the exact same test failing.

Not sure who to reach out to about this test. Ideas are appreciated :)

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.

Rename test classes in Operator testsuite

5 participants