Skip to content

Commit 836253f

Browse files
committed
Use system-specific line separators in ConfigurationWriterTest
1 parent f92fc63 commit 836253f

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

base/src/test/kotlin/proguard/ConfigurationWriterTest.kt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ import java.io.StringWriter
1010
* Test printing of the configuration (-printconfiguration option).
1111
*/
1212
class ConfigurationWriterTest : FreeSpec({
13+
val EOL = System.lineSeparator()
1314
fun printConfiguration(rules: String): String {
1415
val out = StringWriter()
1516
val configuration = Configuration()
@@ -31,11 +32,11 @@ class ConfigurationWriterTest : FreeSpec({
3132
}
3233

3334
"Comments should not be quoted" {
34-
printConfiguration("# comment\n-keep class **") shouldBe "# comment\n-keep class **"
35+
printConfiguration("# comment$EOL-keep class **") shouldBe "# comment$EOL-keep class **"
3536
}
3637

3738
"Hash characters in comments should not be quoted" {
38-
printConfiguration("# #comment\n-keep class **") shouldBe "# #comment\n-keep class **"
39+
printConfiguration("# #comment$EOL-keep class **") shouldBe "# #comment$EOL-keep class **"
3940
}
4041
}
4142

0 commit comments

Comments
 (0)