File tree Expand file tree Collapse file tree 1 file changed +14
-2
lines changed
snack3_demo/src/test/java/features Expand file tree Collapse file tree 1 file changed +14
-2
lines changed Original file line number Diff line number Diff line change 99
1010import java .time .*;
1111import java .util .Date ;
12+ import java .util .HashMap ;
13+ import java .util .Map ;
1214
1315/**
1416 * @author noear 2021/6/13 created
@@ -105,7 +107,17 @@ public void test6() throws Exception {
105107 @ Test
106108 public void test7 () throws Exception {
107109 Date date = new java .sql .Date (DateUtil .parse (LocalDate .now ().toString ()).getTime ());
108- LocalDate day = ONode .load (date ).toObject (LocalDate .class );
109- System .out .println (day .toString ());
110+ Map map = new HashMap ();
111+ map .put ("date" , date );
112+ System .out .println (date );
113+
114+ DateMapModel model = ONode .load (map ).toObject (DateMapModel .class );
115+ System .out .println (model .date .toString ());
116+
117+ assert date .toString ().equals (model .date .toString ());
118+ }
119+
120+ public static class DateMapModel {
121+ public LocalDate date ;
110122 }
111123}
You can’t perform that action at this time.
0 commit comments