Skip to content

Commit

Permalink
Replace deprecated use of toBytes() with Character property `.cod…
Browse files Browse the repository at this point in the history
…e` (#18236)

Addresses the warning which is otherwise output during build asking that we do this.

Closes #18236

COPYBARA_INTEGRATE_REVIEW=#18236 from tempoz:tempoz-fix-deprecated-use-of-to-bytes bb2398c
PiperOrigin-RevId: 673844589
  • Loading branch information
tempoz authored and copybara-github committed Sep 12, 2024
1 parent 3d9f6dc commit 5d9deab
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ class ByteStringsTest {
@Test
fun byteAt() {
val str = "abc".toByteStringUtf8()
assertThat(str[0]).isEqualTo('a'.toByte())
assertThat(str[2]).isEqualTo('c'.toByte())
assertThat(str[0]).isEqualTo('a'.code)
assertThat(str[2]).isEqualTo('c'.code)
}

@Test
Expand Down

0 comments on commit 5d9deab

Please sign in to comment.