I'm trying to convert this Java code to Kotlin ```...
# announcements
h
I'm trying to convert this Java code to Kotlin
Copy code
import org.mockito.Matchers.any
    import org.mockito.Mockito.*
    public class SomeClassTest {
    private static AWSIotClient mockAWSIotClient = mock(AWSIotClient.class);
    
    @Before
    public void setup() throws Exception {
        when(mockAWSIotClient.createCertificateFromCsr(any(CreateCertificateFromCsrRequest.class)))
                .thenReturn(
                    csrResult(CERTIFICATE_IDS.get(0)),
                    csrResult(CERTIFICATE_IDS.get(1))
                );
    }
But I keep getting this error
unresolved reference: java
error
s
@Hexa sanity check question, are you converting for Kotlin/JVM and do you have
kotlin-stdlib-jdk8
included in your dependencies
h
yep I got
org.jetbrains.kotlin:kotlin-stdlib-jdk8
and
apply plugin: 'kotlin'
s
hmm
'org.jetbrains.kotlin.jvm' version '1.2.71'
is what I have
h
let me upgrade my version
im using old version