How can I write tests for a kts script?
# scripting
p
How can I write tests for a kts script?
i
The scripts are compiled into regular kotlin classes, so you can create an instance of it to evaluate. There are some tests for scripts in the kotlin project, e.g. https://github.com/JetBrains/kotlin/blob/master/libraries/tools/kotlin-main-kts-test/test/org/jetbrains/kotlin/mainKts/test/mainKtsTest.kt
p
@Bernardo Ferrari
b
lol, took me months to see this. Thanks!