-
Notifications
You must be signed in to change notification settings - Fork 103
DBRider support #624
Copy link
Copy link
Closed
Labels
recipeRecipe requestRecipe request
Description
What problem are you trying to solve?
Internally, we're using dbrider for integration test that assert db state. It's an extension on top of dbunit that allows for csv datasource annotations on top of test cases.
Between junit4 and 5, there are some changes to the usage.
We could try and create support for this.
Describe the situation before applying the recipe
@AutoConfigureMockMvc
@ActiveProfiles(INTEGRATION_TEST)
@SpringBootTest
@TestExecutionListeners(mergeMode = TestExecutionListeners.MergeMode.MERGE_WITH_DEFAULTS, listeners = {DBRiderTestExecutionListener.class})
@DBUnit(mergeDataSets = true, mergingStrategy = DataSetMergingStrategy.CLASS)
@DataSet(cleanBefore = true, cleanAfter = true, value = "")
public abstract class AbstractIntegrationTest {
...
}Describe the situation after applying the recipe
@AutoConfigureMockMvc
@ActiveProfiles(INTEGRATION_TEST)
@SpringBootTest
@DBRider
@DBUnit(mergeDataSets = true, mergingStrategy = DataSetMergingStrategy.CLASS)
@DataSet(cleanBefore = true, cleanAfter = true, value = "")
public abstract class AbstractIntegrationTest {
...
}Have you considered any alternatives or workarounds?
Manual changes? 🤢
Any additional context
Are you interested in contributing this recipe to OpenRewrite?
I will try to come up with certain aspects, but additional support is always welcome as this is completely greenfielded topic from open rewrite perspective.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
recipeRecipe requestRecipe request
Type
Projects
Status
Done