[Code Analysis. Inspection] IDEA-234302 System.getProperty(str) inspection implementation. Review Refactor

GitOrigin-RevId: e793b2306586a3ea6e12691b5d887fe1cf0b2913
This commit is contained in:
Georgii Ustinov
2023-09-22 15:16:10 +03:00
committed by intellij-monorepo-bot
parent 51fc3a6aeb
commit 883f800574
11 changed files with 115 additions and 113 deletions

View File

@@ -32,7 +32,7 @@ class JavaSystemGetPropertyInspectionTest : SystemGetPropertyInspectionTestBase(
FileSystems.getDefault().getSeparator();
}
}
""".trimIndent(), "Replace with 'java.nio.file.FileSystems.getDefault().getSeparator()'")
""".trimIndent(), "Replace with 'java.nio.file.FileSystems.getDefault().getSeparator()'", true)
}
fun `test quickfix path-separator`() {
@@ -50,7 +50,7 @@ class JavaSystemGetPropertyInspectionTest : SystemGetPropertyInspectionTestBase(
File.pathSeparator;
}
}
""".trimIndent(), "Replace with 'java.io.File.pathSeparator'")
""".trimIndent(), "Replace with 'java.io.File.pathSeparator'", true)
}
fun `test quickfix line-separator`() {
@@ -66,7 +66,7 @@ class JavaSystemGetPropertyInspectionTest : SystemGetPropertyInspectionTestBase(
System.lineSeparator();
}
}
""".trimIndent(), "Replace with 'java.lang.System.lineSeparator()'")
""".trimIndent(), "Replace with 'java.lang.System.lineSeparator()'", true)
}
fun `test quickfix file-encoding`() {
@@ -84,6 +84,6 @@ class JavaSystemGetPropertyInspectionTest : SystemGetPropertyInspectionTestBase(
Charset.defaultCharset().displayName();
}
}
""".trimIndent(), "Replace with 'java.nio.charset.Charset.defaultCharset().displayName()'")
""".trimIndent(), "Replace with 'java.nio.charset.Charset.defaultCharset().displayName()'", true)
}
}