Skip to content

Commit

Permalink
ktlint
Browse files Browse the repository at this point in the history
  • Loading branch information
kochetov committed Jun 17, 2023
1 parent 39d81aa commit d26588c
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,10 @@ class TextExtensionsTest {
val inputText = "This is a test"
val colorHex = ContextCompat.getColor(context, androidx.appcompat.R.color.error_color_material_light)
val subStrings = arrayOf("is", "test")
val expectedOutput =
"Th<span style=\"color:#FF0000;\">is</span> <span style=\"color:#FF0000;\">is</span> a <span style=\"color:#FF0000;\">test</span>".fromHTML()
val expectedOutput = (
"Th<span style=\"color:#FF0000;\">is</span> <span style=\"color:#FF0000;\">" +
"is</span> a <span style=\"color:#FF0000;\">test</span>"
).fromHTML()

val output = inputText.applyColorSpanToSubstrings(colorHex, false, *subStrings)

Expand Down

0 comments on commit d26588c

Please sign in to comment.