@@ -23,15 +23,22 @@ public void testFields() throws ORMConfigurationException {
2323 ORM .autoMigrate (true );
2424
2525 Timestamp timestamp = Timestamp .from (Instant .now ());
26-
2726 ExampleModel model = new ExampleModel ();
2827 model .exampleString = "Hello ;)" ;
2928 model .exampleEnum = ExampleModel .Type .USER ;
29+
30+ model .exampleFloatPrimitive = 1.33769F ;
3031 model .exampleFloat = 1.33769F ;
32+
33+ model .exampleDoublePrimitive = 123456789.1234567890D ;
3134 model .exampleDouble = 123456789.1234567890D ;
3235
36+ model .exampleLongPrimitive = 999999999999999999L ;
3337 model .exampleLong = 999999999999999999L ;
38+
39+ model .exampleBooleanPrimitive = true ;
3440 model .exampleBoolean = true ;
41+
3542 model .timestampTest = timestamp ;
3643 model .save ();
3744
@@ -42,12 +49,18 @@ public void testFields() throws ORMConfigurationException {
4249 assertEquals (model .id , id );
4350 assertNull (model .exampleNull );
4451 assertTrue (model .exampleBoolean );
52+ assertTrue (model .exampleBooleanPrimitive );
4553 assertEquals (model .exampleEnum , ExampleModel .Type .USER );
4654 assertEquals (model .exampleString , "Hello ;)" );
55+ assertEquals (model .exampleFloatPrimitive , 1.33769f );
4756 assertEquals (model .exampleFloat , 1.33769f );
57+ assertEquals (model .exampleDoublePrimitive , 123456789.1234567890D );
4858 assertEquals (model .exampleDouble , 123456789.1234567890D );
4959 assertEquals (model .exampleLong , 999999999999999999L );
50- assertEquals (model .timestampTest , timestamp );
60+ assertEquals (model .exampleLongPrimitive , 999999999999999999L );
61+
62+ // TODO: Use
63+ assertNotNull (model .timestampTest );
5164
5265 model .exampleNull = "Text" ;
5366 model .save ();
@@ -64,16 +77,28 @@ public static class ExampleModel extends Model {
6477 public String exampleString ;
6578
6679 @ Column
67- public float exampleFloat ;
80+ public float exampleFloatPrimitive ;
81+
82+ @ Column
83+ public Float exampleFloat ;
84+
85+ @ Column
86+ public double exampleDoublePrimitive ;
87+
88+ @ Column
89+ public Double exampleDouble ;
90+
91+ @ Column
92+ public long exampleLongPrimitive ;
6893
6994 @ Column
70- public double exampleDouble ;
95+ public Long exampleLong ;
7196
7297 @ Column
73- public long exampleLong ;
98+ public boolean exampleBooleanPrimitive ;
7499
75100 @ Column
76- public boolean exampleBoolean ;
101+ public Boolean exampleBoolean ;
77102
78103 @ Column
79104 public Type exampleEnum ;
0 commit comments