Skip to content

Commit 5c80c62

Browse files
committed
Implement MapExtensionsKtTest
1 parent 602b298 commit 5c80c62

1 file changed

Lines changed: 15 additions & 0 deletions

File tree

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
package org.wordpress.android.util.extensions
2+
3+
import org.assertj.core.api.Assertions.assertThat
4+
import org.junit.Test
5+
6+
class MapExtensionsKtTest {
7+
@Test
8+
fun `Should filter null keys and values in filterNull`() {
9+
mapOf(0 to "0", null to "1", 2 to null, 3 to "3", null to null)
10+
.filterNull().forEach { (key, value) ->
11+
assertThat(key).isNotNull
12+
assertThat(value).isNotNull
13+
}
14+
}
15+
}

0 commit comments

Comments
 (0)