//arrow-meta-test/arrow.meta.plugin.testing/Code/Source

Source

[jvm]
data class Source(val filename: String = DEFAULT_FILENAME, val text: String) : Code

Represents all kind of code snippets: source code to be compiled, expressions, etc.

Constructors

   
Source [jvm]
constructor(filename: String = DEFAULT_FILENAME, text: String)

Functions

Name Summary
evalsTo [jvm]
open override fun Code.Source.evalsTo(value: Any?, onError: (Throwable) -> Any?): Assert.SingleAssert
Checks if a code snippet evals to a provided value after the compilation. This operation loads all the generated classes and run the code snippet by reflection.

Properties

Name Summary
filename [jvm]
val filename: String
Necessary filename to identify different code snippets.
text [jvm]
val text: String
Content of code snippet.

Do you like Arrow?

Arrow Org
<