@@ -13,6 +13,8 @@ import dev.forkhandles.values.IntValue
1313import dev.forkhandles.values.IntValueFactory
1414import dev.forkhandles.values.LocalDateValue
1515import dev.forkhandles.values.LocalDateValueFactory
16+ import dev.forkhandles.values.LongValue
17+ import dev.forkhandles.values.LongValueFactory
1618import dev.forkhandles.values.StringValue
1719import dev.forkhandles.values.StringValueFactory
1820import org.junit.jupiter.api.Test
@@ -68,14 +70,14 @@ interface MainClassFields<C : ChildFields<G>, G : GrandchildFields, CONTENT> {
6870 var optionalData: CONTENT ?
6971 var requiredData: CONTENT
7072
71- var intValue : IntType ?
73+ var longValue : LongType ?
7274 var booleanValue: BooleanType
7375 var stringValue: StringType
7476 var localDateValue: LocalDateType
7577}
7678
77- class IntType private constructor(value : Int ) : IntValue (value) {
78- companion object : IntValueFactory < IntType >(::IntType )
79+ class LongType private constructor(value : Long ) : LongValue (value) {
80+ companion object : LongValueFactory < LongType >(::LongType )
7981}
8082
8183class BooleanType private constructor(value : Boolean ) : BooleanValue(value) {
@@ -134,7 +136,7 @@ abstract class DataContainerContract<C : ChildFields<G>, G : GrandchildFields, C
134136 " stringValue" to " stringValue" ,
135137 " booleanValue" to true ,
136138 " localDateValue" to " 1999-12-31" ,
137- " intValue " to 1 ,
139+ " longValue " to 1 ,
138140 )
139141 )
140142
@@ -153,7 +155,7 @@ abstract class DataContainerContract<C : ChildFields<G>, G : GrandchildFields, C
153155 expectThrows<ClassCastException > { container(mapOf (" mapped" to 123 )).mapped }
154156 expectThat(input.value).isEqualTo(MyType .of(123 ))
155157 expectThat(input.stringValue).isEqualTo(StringType .of(" stringValue" ))
156- expectThat(input.intValue ).isEqualTo(IntType .of(1 ))
158+ expectThat(input.longValue ).isEqualTo(LongType .of(1 ))
157159 expectThat(input.localDateValue).isEqualTo(LocalDateType .of(of(1999 , 12 , 31 )))
158160 expectThat(input.booleanValue).isEqualTo(BooleanType .of(true ))
159161
@@ -181,7 +183,7 @@ abstract class DataContainerContract<C : ChildFields<G>, G : GrandchildFields, C
181183 " localDateValue" to " 1999-12-31" ,
182184 " stringValue" to " stringValue" ,
183185 " booleanValue" to true ,
184- " intValue " to 1
186+ " longValue " to 1
185187 )
186188 )
187189
@@ -192,7 +194,7 @@ abstract class DataContainerContract<C : ChildFields<G>, G : GrandchildFields, C
192194 expectSetWorks(input::long, 0 )
193195 expectSetWorks(input::double, 5.4536 )
194196 expectSetWorks(input::stringValue, StringType .of(" 123" ))
195- expectSetWorks(input::intValue, IntType .of(123 ))
197+ expectSetWorks(input::longValue, LongType .of(123 ))
196198 expectSetWorks(input::localDateValue, LocalDateType .of(of(1999 , 12 , 12 )))
197199 expectSetWorks(input::booleanValue, BooleanType .of(false ))
198200
0 commit comments