diff --git a/platform/diff-impl/tests/com/intellij/diff/comparison/MergeResolveUtilTest.kt b/platform/diff-impl/tests/com/intellij/diff/comparison/MergeResolveUtilTest.kt index 322e69715c56..1283f7ed8f46 100644 --- a/platform/diff-impl/tests/com/intellij/diff/comparison/MergeResolveUtilTest.kt +++ b/platform/diff-impl/tests/com/intellij/diff/comparison/MergeResolveUtilTest.kt @@ -24,35 +24,35 @@ class MergeResolveUtilTest : DiffTestCase() { "", "", "" - ); + ) test( "x x x", "x x x", "x x x", "x x x" - ); + ) test( "x x x", "x Y x", "x x x", "x Y x" - ); + ) test( "x x", "x x", "x Y x", "x Y x" - ); + ) test( "x X x", "x x", "x X x", "x x" - ); + ) } fun testSameModification() { @@ -61,21 +61,21 @@ class MergeResolveUtilTest : DiffTestCase() { "x Y x", "x Y x", "x Y x" - ); + ) test( "x x", "x Y x", "x Y x", "x Y x" - ); + ) test( "x X x", "x x", "x x", "x x" - ); + ) } fun testNonConflictingChanges() { @@ -84,21 +84,21 @@ class MergeResolveUtilTest : DiffTestCase() { "x Y x x", "x x Z x", "x Y x Z x" - ); + ) test( "x", "x Y", "Z x", "Z x Y" - ); + ) test( "x x", "x", "Z x x", "Z x" - ); + ) } fun testFailure() { @@ -107,14 +107,14 @@ class MergeResolveUtilTest : DiffTestCase() { "x Y x", "x Z x", null - ); + ) test( "x x", "x Y x", "x Z x", null - ); + ) } fun testNonFailureConflicts() { @@ -123,35 +123,35 @@ class MergeResolveUtilTest : DiffTestCase() { "x x", "x X Y x", "x Y x" - ); + ) test( "x X x", "x x", "x Y X x", "x Y x" - ); + ) test( "x X Y x", "x X x", "x Y x", "x x" - ); + ) test( "x X Y Z x", "x X x", "x Z x", "x x" - ); + ) test( "x A B C D E F G H K x", "x C F K x", "x A D H x", "x x" - ); + ) } fun testConfusingConflicts() { @@ -162,21 +162,21 @@ class MergeResolveUtilTest : DiffTestCase() { "x x", "x Z x", "xZ x" - ); + ) test( "x X X x", "x X Y X x", "x x", "x Y x" - ); + ) test( "x X x", "x x", "x Y x", "xY x" - ); + ) test( @@ -184,11 +184,11 @@ class MergeResolveUtilTest : DiffTestCase() { "x Y x", "x X Y x", "x Y x" - ); + ) } private fun test(base: String, left: String, right: String, expected: String?) { - val actual = MergeResolveUtil.tryResolveConflict(left, base, right); + val actual = MergeResolveUtil.tryResolveConflict(left, base, right) assertEquals(expected, actual?.toString()) } } diff --git a/platform/diff-impl/tests/com/intellij/diff/comparison/TrimUtilTest.kt b/platform/diff-impl/tests/com/intellij/diff/comparison/TrimUtilTest.kt index 898eeacb6c43..bfbc48a36e89 100644 --- a/platform/diff-impl/tests/com/intellij/diff/comparison/TrimUtilTest.kt +++ b/platform/diff-impl/tests/com/intellij/diff/comparison/TrimUtilTest.kt @@ -19,7 +19,7 @@ import com.intellij.diff.DiffTestCase import com.intellij.openapi.util.text.StringUtil class TrimUtilTest : DiffTestCase() { - private val PUNCTUATION = "(){}[],./?`~!@#$%^&*-=+|\\;:'\"<>"; + private val PUNCTUATION = "(){}[],./?`~!@#$%^&*-=+|\\;:'\"<>" fun testPunctuation() { for (c in Character.MIN_VALUE..Character.MAX_VALUE) { diff --git a/platform/diff-impl/tests/com/intellij/diff/merge/MergeAutoTest.kt b/platform/diff-impl/tests/com/intellij/diff/merge/MergeAutoTest.kt index a9d5e1d14567..9002b6adf776 100644 --- a/platform/diff-impl/tests/com/intellij/diff/merge/MergeAutoTest.kt +++ b/platform/diff-impl/tests/com/intellij/diff/merge/MergeAutoTest.kt @@ -80,8 +80,8 @@ class MergeAutoTest : MergeTestBase() { private fun TestBuilder.doReplace(): Unit { val length = document.textLength - var index1: Int = 0; - var index2: Int = 0; + var index1: Int = 0 + var index2: Int = 0 if (length != 0) { index1 = RNG.nextInt(length) index2 = index1 + RNG.nextInt(length - index1) diff --git a/platform/diff-impl/tests/com/intellij/diff/util/DiffUtilTest.kt b/platform/diff-impl/tests/com/intellij/diff/util/DiffUtilTest.kt index f747b0466f21..376f7ddc717a 100644 --- a/platform/diff-impl/tests/com/intellij/diff/util/DiffUtilTest.kt +++ b/platform/diff-impl/tests/com/intellij/diff/util/DiffUtilTest.kt @@ -51,8 +51,8 @@ class `DiffUtil getSortedIndexes() Test` : DiffTestCase() { private fun doTest(vararg values: T, comparator: (T, T) -> Int) { val list = values.toList() - val sortedIndexes = DiffUtil.getSortedIndexes(list, comparator); - val expected = ContainerUtil.sorted(list, comparator); + val sortedIndexes = DiffUtil.getSortedIndexes(list, comparator) + val expected = ContainerUtil.sorted(list, comparator) val actual = (0..values.size - 1).map { values[sortedIndexes[it]] } assertOrderedEquals(actual, expected) diff --git a/platform/diff-impl/tests/com/intellij/openapi/diff/impl/settings/DiffColorSettingsTest.kt b/platform/diff-impl/tests/com/intellij/openapi/diff/impl/settings/DiffColorSettingsTest.kt index efe20eac5b85..edb3293dbc62 100644 --- a/platform/diff-impl/tests/com/intellij/openapi/diff/impl/settings/DiffColorSettingsTest.kt +++ b/platform/diff-impl/tests/com/intellij/openapi/diff/impl/settings/DiffColorSettingsTest.kt @@ -18,10 +18,8 @@ package com.intellij.openapi.diff.impl.settings import com.intellij.diff.DiffTestCase import com.intellij.diff.tools.simple.SimpleThreesideDiffViewer import com.intellij.diff.util.TextDiffType -import com.intellij.openapi.diff.impl.settings.DiffPreviewPanel import com.intellij.openapi.editor.ex.EditorEx import com.intellij.openapi.editor.markup.RangeHighlighter -import com.intellij.openapi.util.Disposer import com.intellij.testFramework.fixtures.IdeaProjectTestFixture import com.intellij.testFramework.fixtures.IdeaTestFixtureFactory @@ -40,7 +38,7 @@ class DiffColorSettingsTest : DiffTestCase() { } fun testChanges() { - var panel : DiffPreviewPanel? = null; + var panel : DiffPreviewPanel? = null try { panel = DiffPreviewPanel() val viewer = panel.testGetViewer()