Thread
#multiplatform
    r

    Rak

    1 year ago
    Can someone explain what this means:
    implementation(kotlin("test-common"))
    I understand the original gradle format well but I am finding information on the new kts format lacking
    c

    CLOVIS

    1 year ago
    If your question is about the
    Kotlin
    function, just CTRL B on it to see its code, it is really easy to understand.
    r

    Rak

    1 year ago
    If i do that I end up here:
    fun kotlin(simpleModuleName: String, version: String?): ExternalModuleDependency
    That doesn’t really tell me anything.
    I understand its about getting dependencies but i don’t see where
    test-common
    is defined to know what libs and versions that refers to.
    c

    CLOVIS

    1 year ago
    Ah, it brings to an abstract method, sorry. Essentially the idea is that the every Kotlin-related artifact is in group ‘com.whatever-i-don't-recall.jetbrains.kotlin', with the artifact name being ‘kotlin-whatever' and the version should be the same as the version of the
    Kotlin
    plugin. The Kotlin function is just a shorthand to do that instead of writing the full string. If you want to explicitly know what's going on, you can run the gradle task ‘dependencies' which will give you much more details.
    Essentially:
    kotlin("test-common")
    is just a shorthand for
    "org.jetbrains.kotlin:kotlin-test-common:<Kotlin version you specified in the plugins block>"