This repository was archived by the owner on Jan 20, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +10
-5
lines changed
main/kotlin/com/mapk/fastkfunction
test/kotlin/com/mapk/fastkfunction Expand file tree Collapse file tree 2 files changed +10
-5
lines changed Original file line number Diff line number Diff line change @@ -187,8 +187,9 @@ sealed class FastKFunction<T> {
187
187
188
188
(parameters[0 ].type.classifier as KClass <* >).also {
189
189
if (! it.isSuperclassOf(instanceClazz))
190
- throw IllegalArgumentException (" INSTANCE parameter required ${it.simpleName} , " +
191
- " but ${instanceClazz.simpleName} is present." )
190
+ throw IllegalArgumentException (
191
+ " INSTANCE parameter required ${it.simpleName} , but ${instanceClazz.simpleName} is present."
192
+ )
192
193
}
193
194
194
195
val generator = BucketGenerator (parameters, instance)
@@ -203,8 +204,8 @@ sealed class FastKFunction<T> {
203
204
method.declaringClass.kotlin.also { requiredClazz ->
204
205
if (! requiredClazz.isSuperclassOf(instanceClazz))
205
206
throw IllegalArgumentException (
206
- " INSTANCE parameter required ${instanceClazz.simpleName} , "
207
- + " but ${instanceClazz.simpleName} is present."
207
+ " INSTANCE parameter required ${instanceClazz.simpleName} , " +
208
+ " but ${instanceClazz.simpleName} is present."
208
209
)
209
210
}
210
211
Original file line number Diff line number Diff line change @@ -3,9 +3,13 @@ package com.mapk.fastkfunction
3
3
import com.mapk.fastkfunction.FastKFunction.Companion.checkParameters
4
4
import io.mockk.every
5
5
import io.mockk.mockk
6
- import org.junit.jupiter.api.*
7
6
import org.junit.jupiter.api.Assertions.assertEquals
8
7
import org.junit.jupiter.api.Assertions.assertTrue
8
+ import org.junit.jupiter.api.Nested
9
+ import org.junit.jupiter.api.Test
10
+ import org.junit.jupiter.api.TestInstance
11
+ import org.junit.jupiter.api.assertDoesNotThrow
12
+ import org.junit.jupiter.api.assertThrows
9
13
import org.junit.jupiter.params.ParameterizedTest
10
14
import org.junit.jupiter.params.provider.Arguments
11
15
import org.junit.jupiter.params.provider.MethodSource
You can’t perform that action at this time.
0 commit comments