-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Migrate Spark 3.4 TestBase-related remaining tests in actions #12579
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
Migrate Spark 3.4 TestBase-related remaining tests in actions #12579
Conversation
|
Maybe the changes for |
3962c5d to
665adf9
Compare
|
@nastra Could you review this PR when you have time? |
|
|
||
| assertThat(result.rewriteResults()).as("Should have 1 fileGroups").hasSize(1); | ||
| assertThat(result.rewrittenBytesCount()).isEqualTo(dataSizeBefore); | ||
| assertThat(result.rewriteResults()).as("Should have 1 fileGroups").hasSize(1); |
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.
I think this was mistakenly removed and should be added back
| StreamSupport.stream(result.orphanFileLocations().spliterator(), false) | ||
| .anyMatch(file -> file.contains("v1.metadata.json"))); | ||
| assertThat(result.orphanFileLocations()).as("Should delete 1 file").hasSize(1); | ||
| assertThat(StreamSupport.stream(result.orphanFileLocations().spliterator(), false)) |
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.
did you mean to backport the change here without using StreamSupport?
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.
Oh yes, thanks so much for pointing this out. Let me fix.
nastra
left a comment
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.
thanks @tomtongue
|
Thanks for the review!! @nastra |
Migrate Spark 3.4 tests based on JUnit 4 to Junit5 with AssertJ style. This is related to #7160
This PR migrates the other tests in the
spark.actionspackage in Spark 3.4 into JUnit 5 with AssertJ. The following classes are included in this PR:TestRewriteDataFilesActionTestRewriteManifestsActionTestRewriteTablePathsAction(backporting from Spark: Improve assertions for better debuggability #12569)TestRemoveOrphanFilesActionandTestRemoveOrphanFilesAction3