Feature request: It'd be handy to be able to put an annotation on a test class that would change the default assertion mode for any @ExpectedDatabase annotations on methods. We usually use NON_STRICT_UNORDERED mode and it's a little ugly-looking to have to specify that explicitly on every test method.
To be more concrete, I'm asking for something along the lines of,
@DbUnitConfiguration(defaultAssertionMode = DatabaseAssertionMode.NON_STRICT_UNORDERED)
public class MyDbUnitTest {
@Test
@ExpectedDatabase("MyDataSet.xml")
public void testSomeDbStuff() { ... }
}
which would be equivalent to what we do today,
public class MyDbUnitTest {
@Test
@ExpectedDatabase(value = "MyDataSet.xml", assertionMode = DatabaseAssertionMode.NON_STRICT_UNORDERED)
public void testSomeDbStuff() { ... }
}
It's a nice idea but I can't see an easy way to implement it without breaking back compatibility. If you come up with any ideas feel free to submit a pull-request.
Feature request: It'd be handy to be able to put an annotation on a test class that would change the default assertion mode for any
@ExpectedDatabase
annotations on methods. We usually useNON_STRICT_UNORDERED
mode and it's a little ugly-looking to have to specify that explicitly on every test method.To be more concrete, I'm asking for something along the lines of,
which would be equivalent to what we do today,