mirror of
https://github.com/ebean-orm/ebean.git
synced 2024-04-21 10:51:47 +00:00
Fixed tests that modify BasicData (#1530)
This commit is contained in:
committed by
Rob Bygrave
parent
662ffdd070
commit
61eedb4e9a
@@ -4,6 +4,7 @@ import io.ebean.Ebean;
|
||||
import io.ebean.EbeanServer;
|
||||
import org.tests.model.basic.Customer;
|
||||
import org.tests.model.basic.Order;
|
||||
import org.tests.model.basic.ResetBasicData;
|
||||
import org.junit.Test;
|
||||
|
||||
import static org.assertj.core.api.Assertions.assertThat;
|
||||
@@ -80,6 +81,8 @@ public class ExpressionPathTest {
|
||||
@Test
|
||||
public void test_dirty() throws Exception {
|
||||
|
||||
ResetBasicData.reset();
|
||||
|
||||
BeanType<Customer> customerBeanType = beanType(Customer.class);
|
||||
BeanType<Order> orderBeanType = beanType(Order.class);
|
||||
|
||||
@@ -113,6 +116,10 @@ public class ExpressionPathTest {
|
||||
|
||||
order = server.find(Order.class, order.getId());
|
||||
assertThat(order.getCustomer().getName()).isEqualTo("baz");
|
||||
|
||||
// cleanup
|
||||
server.delete(Order.class, order.getId());
|
||||
server.delete(Customer.class, customer.getId());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user