diff options
author | Kamil Doległo <kamilok1965@interia.pl> | 2020-01-31 10:45:29 +0100 |
---|---|---|
committer | Paweł Marks <Kordyjan@users.noreply.github.com> | 2020-01-31 15:27:26 +0100 |
commit | dfa067b6ac1f9ad15902fd82d956cf3b53cba18a (patch) | |
tree | 3cdeeae4af2a0d9441410c5360dac5a6367b12cc /integration-tests/gradle-integration-tests/src/test/kotlin/org/jetbrains | |
parent | e99be615ce7c2c2b5c3ee5e3f8941c41c1e7a944 (diff) | |
download | dokka-dfa067b6ac1f9ad15902fd82d956cf3b53cba18a.tar.gz dokka-dfa067b6ac1f9ad15902fd82d956cf3b53cba18a.tar.bz2 dokka-dfa067b6ac1f9ad15902fd82d956cf3b53cba18a.zip |
Fix Gradle integration tests compilation
Diffstat (limited to 'integration-tests/gradle-integration-tests/src/test/kotlin/org/jetbrains')
2 files changed, 6 insertions, 6 deletions
diff --git a/integration-tests/gradle-integration-tests/src/test/kotlin/org/jetbrains/dokka/gradle/AbstractDokkaGradleTest.kt b/integration-tests/gradle-integration-tests/src/test/kotlin/org/jetbrains/dokka/gradle/AbstractDokkaGradleTest.kt index 4814e707..b2ec1bfb 100644 --- a/integration-tests/gradle-integration-tests/src/test/kotlin/org/jetbrains/dokka/gradle/AbstractDokkaGradleTest.kt +++ b/integration-tests/gradle-integration-tests/src/test/kotlin/org/jetbrains/dokka/gradle/AbstractDokkaGradleTest.kt @@ -1,8 +1,8 @@ package org.jetbrains.dokka.gradle -import com.intellij.rt.execution.junit.FileComparisonFailure import org.gradle.testkit.runner.GradleRunner +import org.junit.ComparisonFailure import org.junit.Rule import org.junit.rules.TemporaryFolder import java.io.File @@ -42,7 +42,7 @@ abstract class AbstractDokkaGradleTest { val noErrorClasses = text.replace(errorClassMarker, "?!") if (noErrorClasses != text) { - throw FileComparisonFailure("", noErrorClasses, text, null) + throw ComparisonFailure("", noErrorClasses, text) } checked++ @@ -59,7 +59,7 @@ abstract class AbstractDokkaGradleTest { val noErrorClasses = text.replace(marker, "?!") if (noErrorClasses != text) { - throw FileComparisonFailure("", noErrorClasses, text, null) + throw ComparisonFailure("", noErrorClasses, text) } checked++ @@ -86,7 +86,7 @@ abstract class AbstractDokkaGradleTest { val expected = textWithoutNonMatches.replace(notMatch, fullLink).replace(match, fullLink) val actual = textWithoutMatches.replace(match, fullLink) - throw FileComparisonFailure("", expected, actual, null) + throw ComparisonFailure("", expected, actual) } if (text != textWithoutMatches) totalEntries++ diff --git a/integration-tests/gradle-integration-tests/src/test/kotlin/org/jetbrains/dokka/gradle/Utils.kt b/integration-tests/gradle-integration-tests/src/test/kotlin/org/jetbrains/dokka/gradle/Utils.kt index 6f17af22..c7ced70b 100644 --- a/integration-tests/gradle-integration-tests/src/test/kotlin/org/jetbrains/dokka/gradle/Utils.kt +++ b/integration-tests/gradle-integration-tests/src/test/kotlin/org/jetbrains/dokka/gradle/Utils.kt @@ -1,6 +1,6 @@ package org.jetbrains.dokka.gradle -import com.intellij.rt.execution.junit.FileComparisonFailure +import org.junit.ComparisonFailure import java.io.File import java.io.IOException import java.nio.file.* @@ -26,7 +26,7 @@ fun assertEqualsIgnoringSeparators(expectedFile: File, output: String) { val actualText = output.replace("\r\n", "\n") if (expectedText != actualText) - throw FileComparisonFailure("", expectedText, actualText, expectedFile.canonicalPath) + throw ComparisonFailure("Output differs! Expected file path: ${expectedFile.canonicalPath}", expectedText, actualText) } class CopyFileVisitor(private var sourcePath: Path?, private val targetPath: Path) : SimpleFileVisitor<Path>() { |