diff --git a/plugins/git4idea/tests/git4idea/push/GitPushOperationSingleRepoTest.kt b/plugins/git4idea/tests/git4idea/push/GitPushOperationSingleRepoTest.kt index 8d2b5506759d..89b9f8cf3bc7 100644 --- a/plugins/git4idea/tests/git4idea/push/GitPushOperationSingleRepoTest.kt +++ b/plugins/git4idea/tests/git4idea/push/GitPushOperationSingleRepoTest.kt @@ -253,7 +253,7 @@ class GitPushOperationSingleRepoTest : GitPushOperationBaseTest() { val log = git("log -3 --pretty=%H#%s") val commits = StringUtil.splitByLines(log) val lastCommitMsg = commits[0].split("#".toRegex()).dropLastWhile { it.isEmpty() }.toTypedArray()[1] - assertTrue("The last commit doesn't look like a merge commit: " + lastCommitMsg, lastCommitMsg.contains("Merge")) + assertTrue("The last commit doesn't look like a merge commit: $lastCommitMsg", lastCommitMsg.contains("Merge")) assertEquals(hash, commits[1].split("#".toRegex()).dropLastWhile { it.isEmpty() }.toTypedArray()[0]) assertEquals(broHash, commits[2].split("#".toRegex()).dropLastWhile { it.isEmpty() }.toTypedArray()[0]) @@ -392,13 +392,13 @@ class GitPushOperationSingleRepoTest : GitPushOperationBaseTest() { }) push("master", "origin/master") - assertTrue("Default action in rejected-push dialog is incorrect: " + defaultActionName, - defaultActionName.toLowerCase().contains("rebase")) + assertTrue("Default action in rejected-push dialog is incorrect: $defaultActionName", + defaultActionName.toLowerCase().contains("rebase")) git("config branch.master.rebase false") push("master", "origin/master") - assertTrue("Default action in rejected-push dialog is incorrect: " + defaultActionName, - defaultActionName.toLowerCase().contains("merge")) + assertTrue("Default action in rejected-push dialog is incorrect: $defaultActionName", + defaultActionName.toLowerCase().contains("merge")) } fun `test respect branch default setting for silent update when rejected push`() { @@ -487,7 +487,7 @@ class GitPushOperationSingleRepoTest : GitPushOperationBaseTest() { private fun assertPushed(expectedHash: String, branch: String) { Executor.cd(parentRepo.path) - val actualHash = git("log -1 --pretty=%H " + branch) + val actualHash = git("log -1 --pretty=%H $branch") assertEquals(expectedHash, actualHash) }