Skip to content

Commit

Permalink
description update
Browse files Browse the repository at this point in the history
  • Loading branch information
manas-yu committed Feb 4, 2025
1 parent e3d5476 commit 2489d0b
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -196,11 +196,10 @@ class ClickableAreasImage(
clickableArea: LabeledRegion,
isSelected: Boolean
): String {
val regionType = clickableArea.region.regionType.name
if (isSelected) {
return "This is a ${regionType.lowercase()} region ${clickableArea.label}."
return "This is a ${clickableArea.label} image."
}
return "Select ${regionType.lowercase()} region ${clickableArea.label}."
return "Select ${clickableArea.label} image."
}

private fun updateRegionContentDescription(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ class ImageRegionSelectionInteractionViewTest {
assertThat(regionClickedEvent.value)
.isEqualTo(
NamedRegionClickedEvent(
regionLabel = "Region 3", contentDescription = "This is a rectangle region Region 3."
regionLabel = "Region 3", contentDescription = "This is a Region 3 image."
)
)
}
Expand Down Expand Up @@ -219,7 +219,7 @@ class ImageRegionSelectionInteractionViewTest {
assertThat(regionClickedEvent.value)
.isEqualTo(
NamedRegionClickedEvent(
regionLabel = "Region 2", contentDescription = "This is a rectangle region Region 2."
regionLabel = "Region 2", contentDescription = "This is a Region 2 image."
)
)
}
Expand All @@ -233,7 +233,7 @@ class ImageRegionSelectionInteractionViewTest {
onView(
allOf(
withTagValue(`is`("Region 3")),
withContentDescription("Select rectangle region Region 3.")
withContentDescription("Select Region 3 image.")
)
).check(matches(isDisplayed()))
}
Expand Down Expand Up @@ -295,7 +295,7 @@ class ImageRegionSelectionInteractionViewTest {
assertThat(regionClickedEvent.value)
.isEqualTo(
NamedRegionClickedEvent(
regionLabel = "Region 2", contentDescription = "This is a rectangle region Region 2."
regionLabel = "Region 2", contentDescription = "This is a Region 2 image."
)
)
}
Expand Down Expand Up @@ -323,7 +323,7 @@ class ImageRegionSelectionInteractionViewTest {
assertThat(regionClickedEvent.value)
.isEqualTo(
NamedRegionClickedEvent(
regionLabel = "Region 3", contentDescription = "This is a rectangle region Region 3."
regionLabel = "Region 3", contentDescription = "This is a Region 3 image."
)
)
}
Expand Down Expand Up @@ -367,7 +367,7 @@ class ImageRegionSelectionInteractionViewTest {
assertThat(regionClickedEvent.value)
.isEqualTo(
NamedRegionClickedEvent(
regionLabel = "Region 3", contentDescription = "This is a rectangle region Region 3."
regionLabel = "Region 3", contentDescription = "This is a Region 3 image."
)
)
}
Expand Down Expand Up @@ -409,7 +409,7 @@ class ImageRegionSelectionInteractionViewTest {
assertThat(regionClickedEvent.value)
.isEqualTo(
NamedRegionClickedEvent(
regionLabel = "Region 2", contentDescription = "This is a rectangle region Region 2."
regionLabel = "Region 2", contentDescription = "This is a Region 2 image."
)
)
}
Expand Down

0 comments on commit 2489d0b

Please sign in to comment.