Add samples for coerceAtMost

#KT-20357
This commit is contained in:
shiraji
2018-01-10 11:22:39 +09:00
committed by Ilya Gorbunov
parent db607e231c
commit 4559da9848
5 changed files with 27 additions and 0 deletions
@@ -26,4 +26,9 @@ class ComparableOps {
assertPrints(10.coerceAtLeast(20), "20")
}
@Sample
fun coerceAtMost() {
assertPrints(10.coerceAtMost(5), "5")
assertPrints(10.coerceAtMost(20), "10")
}
}