-
Notifications
You must be signed in to change notification settings - Fork 141
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
[Minor] refactor test code #432
Conversation
ShuffleServerConf conf = new ShuffleServerConf(); | ||
conf.setBoolean(ShuffleServerConf.HEALTH_CHECK_ENABLE, true); | ||
conf.setString(ShuffleServerConf.RSS_STORAGE_TYPE, StorageType.LOCALFILE.name()); | ||
conf.set(ShuffleServerConf.RSS_STORAGE_BASE_PATH, Arrays.asList("st1", "st2", "st3")); |
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.
This creates empty dirs: st1,st2,st3 under repo dir when running in IDEs.
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.
You are right. Could u help do some cleanup after test finished?
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.
After this change. The st1, st2, st3 should be deleted automatically since they are guarded by the @TempDir
annotation.
Is there anything I'm missing here?
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.
You are right.
Codecov Report
@@ Coverage Diff @@
## master #432 +/- ##
============================================
+ Coverage 58.53% 58.61% +0.07%
- Complexity 1615 1619 +4
============================================
Files 195 195
Lines 11042 11044 +2
Branches 973 973
============================================
+ Hits 6463 6473 +10
+ Misses 4202 4195 -7
+ Partials 377 376 -1
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
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.
LGTM.
I will approve first. If you have some changes, please amend them
0798d88
to
7e008dc
Compare
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.
LGTM
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.
LGTM
Thanks. Merged. |
What changes were proposed in this pull request?
Refactor some test code
Why are the changes needed?
For better code quality. And fixes some flaky test such as #388
Does this PR introduce any user-facing change?
No
How was this patch tested?
Existing UTs. There should be no logic change.