mirror of
https://github.com/anyproto/anytype-kotlin.git
synced 2025-06-08 05:47:05 +09:00
Sets | Support new filters "Exact in" and "not exact in" (#2422)
This commit is contained in:
parent
68c7636e28
commit
98afdd9726
6 changed files with 313 additions and 70 deletions
|
@ -16,7 +16,6 @@ typealias DVViewerType = Block.Content.DataView.Viewer.Type
|
|||
typealias DVViewerCardSize= Block.Content.DataView.Viewer.Size
|
||||
typealias DVFilter = Block.Content.DataView.Filter
|
||||
typealias DVFilterCondition = Block.Content.DataView.Filter.Condition
|
||||
typealias DVFilterConditionType = Block.Content.DataView.Filter.ConditionType
|
||||
typealias DVFilterOperator = Block.Content.DataView.Filter.Operator
|
||||
typealias DVSort = Block.Content.DataView.Sort
|
||||
typealias DVSortType = Block.Content.DataView.Sort.Type
|
||||
|
|
|
@ -337,8 +337,6 @@ data class Block(
|
|||
LIKE, NOT_LIKE, IN, NOT_IN, EMPTY, NOT_EMPTY, ALL_IN, NOT_ALL_IN, NONE,
|
||||
EXACT_IN, NOT_EXACT_IN
|
||||
}
|
||||
|
||||
enum class ConditionType { TEXT, NUMBER, SELECT, CHECKBOX }
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1,9 +1,10 @@
|
|||
package com.anytypeio.anytype.presentation.extension
|
||||
|
||||
import com.anytypeio.anytype.core_models.DVFilterCondition
|
||||
import com.anytypeio.anytype.core_models.DVFilterConditionType
|
||||
import com.anytypeio.anytype.core_models.Relation
|
||||
import com.anytypeio.anytype.presentation.sets.filter.DVFilterConditionCategory
|
||||
import com.anytypeio.anytype.presentation.sets.model.Viewer
|
||||
import timber.log.Timber
|
||||
|
||||
fun Viewer.Filter.Condition.index(): Int = this.getConditions().indexOf(this)
|
||||
|
||||
|
@ -28,127 +29,133 @@ fun Relation.toConditionView(condition: DVFilterCondition?): Viewer.Filter.Condi
|
|||
Relation.Format.URL,
|
||||
Relation.Format.EMAIL,
|
||||
Relation.Format.PHONE -> {
|
||||
condition?.toView(conditionType = DVFilterConditionType.TEXT)
|
||||
condition?.toView(category = DVFilterConditionCategory.TEXT)
|
||||
?: Viewer.Filter.Condition.Text.textConditions().first()
|
||||
}
|
||||
Relation.Format.NUMBER,
|
||||
Relation.Format.DATE -> {
|
||||
condition?.toView(conditionType = DVFilterConditionType.NUMBER)
|
||||
condition?.toView(category = DVFilterConditionCategory.NUMBER)
|
||||
?: Viewer.Filter.Condition.Number.numberConditions().first()
|
||||
}
|
||||
Relation.Format.STATUS,
|
||||
Relation.Format.TAG,
|
||||
Relation.Format.OBJECT -> {
|
||||
condition?.toView(conditionType = DVFilterConditionType.SELECT)
|
||||
condition?.toView(category = DVFilterConditionCategory.SELECT)
|
||||
?: Viewer.Filter.Condition.Selected.selectConditions().first()
|
||||
}
|
||||
Relation.Format.CHECKBOX -> {
|
||||
condition?.toView(conditionType = DVFilterConditionType.CHECKBOX)
|
||||
condition?.toView(category = DVFilterConditionCategory.CHECKBOX)
|
||||
?: Viewer.Filter.Condition.Checkbox.checkboxConditions().first()
|
||||
}
|
||||
else -> throw UnsupportedOperationException("Unsupported relation format:${format}")
|
||||
}
|
||||
|
||||
private fun DVFilterCondition.toView(
|
||||
conditionType: DVFilterConditionType
|
||||
): Viewer.Filter.Condition = when (this) {
|
||||
category: DVFilterConditionCategory
|
||||
): Viewer.Filter.Condition? = when (this) {
|
||||
DVFilterCondition.EQUAL -> {
|
||||
when (conditionType) {
|
||||
DVFilterConditionType.TEXT -> Viewer.Filter.Condition.Text.Equal()
|
||||
DVFilterConditionType.NUMBER -> Viewer.Filter.Condition.Number.Equal()
|
||||
DVFilterConditionType.SELECT -> Viewer.Filter.Condition.Selected.Equal()
|
||||
DVFilterConditionType.CHECKBOX -> Viewer.Filter.Condition.Checkbox.Equal()
|
||||
when (category) {
|
||||
DVFilterConditionCategory.TEXT -> Viewer.Filter.Condition.Text.Equal()
|
||||
DVFilterConditionCategory.NUMBER -> Viewer.Filter.Condition.Number.Equal()
|
||||
DVFilterConditionCategory.SELECT -> Viewer.Filter.Condition.Selected.Equal()
|
||||
DVFilterConditionCategory.CHECKBOX -> Viewer.Filter.Condition.Checkbox.Equal()
|
||||
}
|
||||
}
|
||||
DVFilterCondition.NOT_EQUAL -> {
|
||||
when (conditionType) {
|
||||
DVFilterConditionType.TEXT -> Viewer.Filter.Condition.Text.NotEqual()
|
||||
DVFilterConditionType.NUMBER -> Viewer.Filter.Condition.Number.NotEqual()
|
||||
DVFilterConditionType.CHECKBOX -> Viewer.Filter.Condition.Checkbox.NotEqual()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $conditionType")
|
||||
when (category) {
|
||||
DVFilterConditionCategory.TEXT -> Viewer.Filter.Condition.Text.NotEqual()
|
||||
DVFilterConditionCategory.NUMBER -> Viewer.Filter.Condition.Number.NotEqual()
|
||||
DVFilterConditionCategory.CHECKBOX -> Viewer.Filter.Condition.Checkbox.NotEqual()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $category")
|
||||
}
|
||||
}
|
||||
DVFilterCondition.GREATER -> {
|
||||
when (conditionType) {
|
||||
DVFilterConditionType.NUMBER -> Viewer.Filter.Condition.Number.Greater()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $conditionType")
|
||||
when (category) {
|
||||
DVFilterConditionCategory.NUMBER -> Viewer.Filter.Condition.Number.Greater()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $category")
|
||||
}
|
||||
}
|
||||
DVFilterCondition.LESS -> {
|
||||
when (conditionType) {
|
||||
DVFilterConditionType.NUMBER -> Viewer.Filter.Condition.Number.Less()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $conditionType")
|
||||
when (category) {
|
||||
DVFilterConditionCategory.NUMBER -> Viewer.Filter.Condition.Number.Less()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $category")
|
||||
}
|
||||
}
|
||||
DVFilterCondition.GREATER_OR_EQUAL -> {
|
||||
when (conditionType) {
|
||||
DVFilterConditionType.NUMBER -> Viewer.Filter.Condition.Number.GreaterOrEqual()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $conditionType")
|
||||
when (category) {
|
||||
DVFilterConditionCategory.NUMBER -> Viewer.Filter.Condition.Number.GreaterOrEqual()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $category")
|
||||
}
|
||||
}
|
||||
DVFilterCondition.LESS_OR_EQUAL -> {
|
||||
when (conditionType) {
|
||||
DVFilterConditionType.NUMBER -> Viewer.Filter.Condition.Number.LessOrEqual()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $conditionType")
|
||||
when (category) {
|
||||
DVFilterConditionCategory.NUMBER -> Viewer.Filter.Condition.Number.LessOrEqual()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $category")
|
||||
}
|
||||
}
|
||||
DVFilterCondition.LIKE -> {
|
||||
when (conditionType) {
|
||||
DVFilterConditionType.TEXT -> Viewer.Filter.Condition.Text.Like()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $conditionType")
|
||||
when (category) {
|
||||
DVFilterConditionCategory.TEXT -> Viewer.Filter.Condition.Text.Like()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $category")
|
||||
}
|
||||
}
|
||||
DVFilterCondition.NOT_LIKE -> {
|
||||
when (conditionType) {
|
||||
DVFilterConditionType.TEXT -> Viewer.Filter.Condition.Text.NotLike()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $conditionType")
|
||||
when (category) {
|
||||
DVFilterConditionCategory.TEXT -> Viewer.Filter.Condition.Text.NotLike()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $category")
|
||||
}
|
||||
}
|
||||
DVFilterCondition.IN -> {
|
||||
when (conditionType) {
|
||||
DVFilterConditionType.SELECT -> Viewer.Filter.Condition.Selected.In()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $conditionType")
|
||||
when (category) {
|
||||
DVFilterConditionCategory.SELECT -> Viewer.Filter.Condition.Selected.In()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $category")
|
||||
}
|
||||
}
|
||||
DVFilterCondition.NOT_IN -> {
|
||||
when (conditionType) {
|
||||
DVFilterConditionType.SELECT -> Viewer.Filter.Condition.Selected.NotIn()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $conditionType")
|
||||
when (category) {
|
||||
DVFilterConditionCategory.SELECT -> Viewer.Filter.Condition.Selected.NotIn()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $category")
|
||||
}
|
||||
}
|
||||
DVFilterCondition.EMPTY -> {
|
||||
when (conditionType) {
|
||||
DVFilterConditionType.TEXT -> Viewer.Filter.Condition.Text.Empty()
|
||||
DVFilterConditionType.SELECT -> Viewer.Filter.Condition.Selected.Empty()
|
||||
DVFilterConditionType.NUMBER -> Viewer.Filter.Condition.Number.Empty()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $conditionType")
|
||||
when (category) {
|
||||
DVFilterConditionCategory.TEXT -> Viewer.Filter.Condition.Text.Empty()
|
||||
DVFilterConditionCategory.SELECT -> Viewer.Filter.Condition.Selected.Empty()
|
||||
DVFilterConditionCategory.NUMBER -> Viewer.Filter.Condition.Number.Empty()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $category")
|
||||
}
|
||||
}
|
||||
DVFilterCondition.NOT_EMPTY -> {
|
||||
when (conditionType) {
|
||||
DVFilterConditionType.TEXT -> Viewer.Filter.Condition.Text.NotEmpty()
|
||||
DVFilterConditionType.SELECT -> Viewer.Filter.Condition.Selected.NotEmpty()
|
||||
DVFilterConditionType.NUMBER -> Viewer.Filter.Condition.Number.NotEmpty()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $conditionType")
|
||||
when (category) {
|
||||
DVFilterConditionCategory.TEXT -> Viewer.Filter.Condition.Text.NotEmpty()
|
||||
DVFilterConditionCategory.SELECT -> Viewer.Filter.Condition.Selected.NotEmpty()
|
||||
DVFilterConditionCategory.NUMBER -> Viewer.Filter.Condition.Number.NotEmpty()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $category")
|
||||
}
|
||||
}
|
||||
DVFilterCondition.ALL_IN -> {
|
||||
when (conditionType) {
|
||||
DVFilterConditionType.SELECT -> Viewer.Filter.Condition.Selected.AllIn()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $conditionType")
|
||||
when (category) {
|
||||
DVFilterConditionCategory.SELECT -> Viewer.Filter.Condition.Selected.AllIn()
|
||||
else -> throw IllegalArgumentException("Condition ${this.name} is not present in $category")
|
||||
}
|
||||
}
|
||||
DVFilterCondition.NOT_ALL_IN -> {
|
||||
throw IllegalArgumentException("Condition ${this.name} is not present in $conditionType")
|
||||
throw IllegalArgumentException("Condition ${this.name} is not present in $category")
|
||||
}
|
||||
DVFilterCondition.NONE -> {
|
||||
when (conditionType) {
|
||||
DVFilterConditionType.TEXT -> Viewer.Filter.Condition.Text.None()
|
||||
DVFilterConditionType.NUMBER -> Viewer.Filter.Condition.Number.None()
|
||||
DVFilterConditionType.SELECT -> Viewer.Filter.Condition.Selected.None()
|
||||
DVFilterConditionType.CHECKBOX -> Viewer.Filter.Condition.Checkbox.None()
|
||||
when (category) {
|
||||
DVFilterConditionCategory.TEXT -> Viewer.Filter.Condition.Text.None()
|
||||
DVFilterConditionCategory.NUMBER -> Viewer.Filter.Condition.Number.None()
|
||||
DVFilterConditionCategory.SELECT -> Viewer.Filter.Condition.Selected.None()
|
||||
DVFilterConditionCategory.CHECKBOX -> Viewer.Filter.Condition.Checkbox.None()
|
||||
}
|
||||
}
|
||||
DVFilterCondition.EXACT_IN -> TODO()
|
||||
DVFilterCondition.NOT_EXACT_IN -> TODO()
|
||||
DVFilterCondition.EXACT_IN -> {
|
||||
Timber.w("Unexpected filter condition: EXACT IN")
|
||||
null
|
||||
}
|
||||
DVFilterCondition.NOT_EXACT_IN -> {
|
||||
Timber.w("Unexpected filter condition: NOT EXACT IN")
|
||||
null
|
||||
}
|
||||
}
|
|
@ -0,0 +1,3 @@
|
|||
package com.anytypeio.anytype.presentation.sets.filter
|
||||
|
||||
enum class DVFilterConditionCategory { TEXT, NUMBER, SELECT, CHECKBOX }
|
|
@ -176,8 +176,15 @@ sealed class Viewer {
|
|||
}
|
||||
|
||||
companion object {
|
||||
fun textConditions() =
|
||||
listOf(Equal(), NotEqual(), Like(), NotLike(), Empty(), NotEmpty(), None())
|
||||
fun textConditions() = listOf(
|
||||
Equal(),
|
||||
NotEqual(),
|
||||
Like(),
|
||||
NotLike(),
|
||||
Empty(),
|
||||
NotEmpty(),
|
||||
None()
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -282,8 +289,15 @@ sealed class Viewer {
|
|||
}
|
||||
|
||||
companion object {
|
||||
fun selectConditions() =
|
||||
listOf(In(), AllIn(), Equal(), NotIn(), Empty(), NotEmpty(), None())
|
||||
fun selectConditions() = listOf(
|
||||
In(),
|
||||
AllIn(),
|
||||
Equal(),
|
||||
NotIn(),
|
||||
Empty(),
|
||||
NotEmpty(),
|
||||
None()
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -304,7 +318,11 @@ sealed class Viewer {
|
|||
}
|
||||
|
||||
companion object {
|
||||
fun checkboxConditions() = listOf(Equal(), NotEqual(), None())
|
||||
fun checkboxConditions() = listOf(
|
||||
Equal(),
|
||||
NotEqual(),
|
||||
None()
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1453,4 +1453,222 @@ class FilterConditionExtensionTest {
|
|||
relationCheckbox.toConditionView(condition = DVFilterCondition.NOT_EMPTY)
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
fun `should return default values for exact-in condition`() {
|
||||
val relationTextLong = Relation(
|
||||
key = MockDataFactory.randomUuid(),
|
||||
name = MockDataFactory.randomString(),
|
||||
format = Relation.Format.LONG_TEXT,
|
||||
source = Relation.Source.ACCOUNT,
|
||||
isHidden = false,
|
||||
isReadOnly = false,
|
||||
isMulti = false,
|
||||
selections = emptyList(),
|
||||
defaultValue = MockDataFactory.randomString()
|
||||
)
|
||||
val relationTextShort = relationTextLong.copy(
|
||||
format = Relation.Format.SHORT_TEXT
|
||||
)
|
||||
val relationUrl = relationTextLong.copy(
|
||||
format = Relation.Format.URL
|
||||
)
|
||||
val relationPhone = relationTextLong.copy(
|
||||
format = Relation.Format.PHONE
|
||||
)
|
||||
val relationEmail = relationTextLong.copy(
|
||||
format = Relation.Format.EMAIL
|
||||
)
|
||||
val relationNumber = relationTextLong.copy(
|
||||
format = Relation.Format.NUMBER
|
||||
)
|
||||
val relationDate = relationTextLong.copy(
|
||||
format = Relation.Format.DATE
|
||||
)
|
||||
val relationTag = relationTextLong.copy(
|
||||
format = Relation.Format.TAG
|
||||
)
|
||||
val relationStatus = relationTextLong.copy(
|
||||
format = Relation.Format.STATUS
|
||||
)
|
||||
val relationObject = relationTextLong.copy(
|
||||
format = Relation.Format.OBJECT
|
||||
)
|
||||
val relationCheckbox = relationTextLong.copy(
|
||||
format = Relation.Format.CHECKBOX
|
||||
)
|
||||
|
||||
val expectedText = Viewer.Filter.Condition.Text.Equal()
|
||||
val expectedSelected = Viewer.Filter.Condition.Selected.In()
|
||||
val expectedNumber = Viewer.Filter.Condition.Number.Equal()
|
||||
val expectedCheckbox = Viewer.Filter.Condition.Checkbox.Equal()
|
||||
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedText,
|
||||
actual = relationTextLong.toConditionView(condition = DVFilterCondition.EXACT_IN)
|
||||
)
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedText,
|
||||
actual = relationTextShort.toConditionView(condition = DVFilterCondition.EXACT_IN)
|
||||
)
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedText,
|
||||
actual = relationPhone.toConditionView(condition = DVFilterCondition.EXACT_IN)
|
||||
)
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedText,
|
||||
actual = relationEmail.toConditionView(condition = DVFilterCondition.EXACT_IN)
|
||||
)
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedText,
|
||||
actual = relationUrl.toConditionView(condition = DVFilterCondition.EXACT_IN)
|
||||
)
|
||||
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedNumber,
|
||||
actual = relationNumber.toConditionView(condition = DVFilterCondition.EXACT_IN)
|
||||
)
|
||||
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedNumber,
|
||||
actual = relationDate.toConditionView(condition = DVFilterCondition.EXACT_IN)
|
||||
)
|
||||
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedSelected,
|
||||
actual = relationTag.toConditionView(condition = DVFilterCondition.EXACT_IN)
|
||||
)
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedSelected,
|
||||
actual = relationStatus.toConditionView(condition = DVFilterCondition.EXACT_IN)
|
||||
)
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedSelected,
|
||||
actual = relationObject.toConditionView(condition = DVFilterCondition.EXACT_IN)
|
||||
)
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedCheckbox,
|
||||
actual = relationCheckbox.toConditionView(condition = DVFilterCondition.NOT_EXACT_IN)
|
||||
)
|
||||
}
|
||||
|
||||
@Test
|
||||
fun `should return default values for not-exact-in condition`() {
|
||||
val relationTextLong = Relation(
|
||||
key = MockDataFactory.randomUuid(),
|
||||
name = MockDataFactory.randomString(),
|
||||
format = Relation.Format.LONG_TEXT,
|
||||
source = Relation.Source.ACCOUNT,
|
||||
isHidden = false,
|
||||
isReadOnly = false,
|
||||
isMulti = false,
|
||||
selections = emptyList(),
|
||||
defaultValue = MockDataFactory.randomString()
|
||||
)
|
||||
val relationTextShort = relationTextLong.copy(
|
||||
format = Relation.Format.SHORT_TEXT
|
||||
)
|
||||
val relationUrl = relationTextLong.copy(
|
||||
format = Relation.Format.URL
|
||||
)
|
||||
val relationPhone = relationTextLong.copy(
|
||||
format = Relation.Format.PHONE
|
||||
)
|
||||
val relationEmail = relationTextLong.copy(
|
||||
format = Relation.Format.EMAIL
|
||||
)
|
||||
val relationNumber = relationTextLong.copy(
|
||||
format = Relation.Format.NUMBER
|
||||
)
|
||||
val relationDate = relationTextLong.copy(
|
||||
format = Relation.Format.DATE
|
||||
)
|
||||
val relationTag = relationTextLong.copy(
|
||||
format = Relation.Format.TAG
|
||||
)
|
||||
val relationStatus = relationTextLong.copy(
|
||||
format = Relation.Format.STATUS
|
||||
)
|
||||
val relationObject = relationTextLong.copy(
|
||||
format = Relation.Format.OBJECT
|
||||
)
|
||||
val relationCheckbox = relationTextLong.copy(
|
||||
format = Relation.Format.CHECKBOX
|
||||
)
|
||||
|
||||
val expectedText = Viewer.Filter.Condition.Text.Equal()
|
||||
val expectedSelected = Viewer.Filter.Condition.Selected.In()
|
||||
val expectedNumber = Viewer.Filter.Condition.Number.Equal()
|
||||
val expectedCheckbox = Viewer.Filter.Condition.Checkbox.Equal()
|
||||
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedText,
|
||||
actual = relationTextLong.toConditionView(condition = DVFilterCondition.NOT_EXACT_IN)
|
||||
)
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedText,
|
||||
actual = relationTextShort.toConditionView(condition = DVFilterCondition.NOT_EXACT_IN)
|
||||
)
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedText,
|
||||
actual = relationPhone.toConditionView(condition = DVFilterCondition.NOT_EXACT_IN)
|
||||
)
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedText,
|
||||
actual = relationEmail.toConditionView(condition = DVFilterCondition.NOT_EXACT_IN)
|
||||
)
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedText,
|
||||
actual = relationUrl.toConditionView(condition = DVFilterCondition.NOT_EXACT_IN)
|
||||
)
|
||||
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedNumber,
|
||||
actual = relationNumber.toConditionView(condition = DVFilterCondition.NOT_EXACT_IN)
|
||||
)
|
||||
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedNumber,
|
||||
actual = relationDate.toConditionView(condition = DVFilterCondition.NOT_EXACT_IN)
|
||||
)
|
||||
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedSelected,
|
||||
actual = relationTag.toConditionView(condition = DVFilterCondition.NOT_EXACT_IN)
|
||||
)
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedSelected,
|
||||
actual = relationStatus.toConditionView(condition = DVFilterCondition.NOT_EXACT_IN)
|
||||
)
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedSelected,
|
||||
actual = relationObject.toConditionView(condition = DVFilterCondition.NOT_EXACT_IN)
|
||||
)
|
||||
asserter.assertEquals(
|
||||
message = null,
|
||||
expected = expectedCheckbox,
|
||||
actual = relationCheckbox.toConditionView(condition = DVFilterCondition.NOT_EXACT_IN)
|
||||
)
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue