Closed rmpestano closed 8 years ago
Currently empty datasets are not supported.They are extremely useful for dataset comparison where e.g you expect an empty table after rows where deleted in test:
empty.yml
user: follower: tweet:
user.yml
user: - id: 1 name: "@realpestano" - id: 2 name: "@dbunit"
the test:
@Test @DataSet(value = "yml/user.yml", disableConstraints = true) @ExpectedDataSet(value = "yml/empty.yml") public void shouldMatchEmptyYmlDataSet() { tx().begin(); em().remove(em().find(User.class,1L)); em().remove(em().find(User.class,2L)); tx().commit(); }
Currently empty datasets are not supported.They are extremely useful for dataset comparison where e.g you expect an empty table after rows where deleted in test:
empty.yml
user.yml
the test: