mirror of
https://github.com/ebean-orm/ebean.git
synced 2024-04-21 10:51:47 +00:00
FIX: jsonRead of transient maps (#1389)
FIX: jsonRead of transient maps - to skip the read of start_array - Avoid error "Unexpected token start_object - expecting start_array "
This commit is contained in:
committed by
Rob Bygrave
parent
8ea86d6c6d
commit
5a7f24da5d
@@ -5,6 +5,7 @@ import io.ebean.Ebean;
|
||||
import org.ebeantest.LoggedSqlCollector;
|
||||
import org.junit.Test;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@@ -137,6 +138,7 @@ public class TestElementCollectionBasicMap extends BaseTestCase {
|
||||
}
|
||||
|
||||
private void jsonToFrom(EcmPerson foundFirst) {
|
||||
foundFirst.transientPhoneNumbers = new HashMap<>();
|
||||
String asJson = Ebean.json().toJson(foundFirst);
|
||||
EcmPerson fromJson = Ebean.json().toBean(EcmPerson.class, asJson);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user