diff --git a/libs/fluxc/src/test/java/org/wordpress/android/fluxc/comment/CommentSqlUtilsTest.kt b/libs/fluxc/src/test/java/org/wordpress/android/fluxc/comment/CommentSqlUtilsTest.kt index ad134539f92b..f7de0d5a2bca 100644 --- a/libs/fluxc/src/test/java/org/wordpress/android/fluxc/comment/CommentSqlUtilsTest.kt +++ b/libs/fluxc/src/test/java/org/wordpress/android/fluxc/comment/CommentSqlUtilsTest.kt @@ -179,9 +179,9 @@ class CommentSqlUtilsTest { val commentsInDb = generateCommentModels(60, ALL) val remoteComments = generateCommentModels(30, ALL) - remoteComments.removeLast() - remoteComments.removeLast() - remoteComments.removeLast() + remoteComments.removeAt(remoteComments.lastIndex) + remoteComments.removeAt(remoteComments.lastIndex) + remoteComments.removeAt(remoteComments.lastIndex) commentsInDb.forEach { CommentSqlUtils.insertOrUpdateComment(it)