From 7fbff24a81a7bcc453e1c4e30acdcf7b38c68265 Mon Sep 17 00:00:00 2001 From: Dmitry Jemerov Date: Fri, 9 Jan 2015 18:54:06 +0100 Subject: use JUnit for compares; avoid generating trailing whitespace in markdown --- test/data/format/annotationClass.md | 2 +- test/data/format/annotations.md | 6 +++--- test/data/format/classWithClassObject.md | 6 +++--- test/src/TestAPI.kt | 5 ++--- 4 files changed, 9 insertions(+), 10 deletions(-) (limited to 'test') diff --git a/test/data/format/annotationClass.md b/test/data/format/annotationClass.md index bfaa8581..301eff08 100644 --- a/test/data/format/annotationClass.md +++ b/test/data/format/annotationClass.md @@ -14,5 +14,5 @@ annotation class fancy ### Constructors -| [<init>](out.md) | `public fancy()` | +| [<init>](out.md) | `public fancy()` | diff --git a/test/data/format/annotations.md b/test/data/format/annotations.md index 83f79397..e745213e 100644 --- a/test/data/format/annotations.md +++ b/test/data/format/annotations.md @@ -14,17 +14,17 @@ data class Foo ### Constructors -| [<init>](out.md) | `public Foo()` | +| [<init>](out.md) | `public Foo()` | ### Properties -| [x](out.md) | `inline val x: Int` | +| [x](out.md) | `inline val x: Int` | ### Functions -| [bar](out.md) | `inline fun bar(noinline notInlined: () -> Unit): Unit` | +| [bar](out.md) | `inline fun bar(noinline notInlined: () -> Unit): Unit` | diff --git a/test/data/format/classWithClassObject.md b/test/data/format/classWithClassObject.md index f694a76f..796ecce2 100644 --- a/test/data/format/classWithClassObject.md +++ b/test/data/format/classWithClassObject.md @@ -14,17 +14,17 @@ class Klass ### Constructors -| [<init>](out.md) | `public Klass()` | +| [<init>](out.md) | `public Klass()` | ### Class Object Properties -| [x](out.md) | `val x: Int` | +| [x](out.md) | `val x: Int` | ### Class Object Functions -| [foo](out.md) | `fun foo(): Unit` | +| [foo](out.md) | `fun foo(): Unit` | diff --git a/test/src/TestAPI.kt b/test/src/TestAPI.kt index a88835cd..e559e337 100644 --- a/test/src/TestAPI.kt +++ b/test/src/TestAPI.kt @@ -4,10 +4,9 @@ import org.jetbrains.jet.cli.common.messages.* import com.intellij.openapi.util.* import kotlin.test.fail import org.jetbrains.dokka.* -import org.jetbrains.jet.lang.descriptors.DeclarationDescriptor import java.io.File -import kotlin.test.assertEquals import com.intellij.openapi.application.PathManager +import org.junit.Assert public fun verifyModel(vararg files: String, verifier: (DocumentationModule) -> Unit) { val messageCollector = object : MessageCollector { @@ -55,7 +54,7 @@ public fun verifyOutput(path: String, outputExtension: String, outputGenerator: val output = StringBuilder() outputGenerator(it, output) val expectedOutput = File(path.replace(".kt", outputExtension)).readText() - assertEquals(expectedOutput, output.toString()) + Assert.assertEquals(expectedOutput, output.toString()) } } -- cgit