NEW: ExpressionList has clear() method

This commit is contained in:
Roland Praml
2023-01-23 11:33:29 +01:00
parent 09a831f2d6
commit 371f50fb4d
4 changed files with 23 additions and 0 deletions
@@ -99,6 +99,14 @@ public class DefaultExpressionListTest extends BaseExpressionTest {
.isSameByBind(spi(exp().eq("a", 10).eq("b", 20)))).isFalse();
}
@Test
public void isSameWithClear() {
DefaultExpressionList<?> exp1 = spi(exp().eq("a", 10).eq("b", 20).clear().eq("c", 30));
DefaultExpressionList<?> exp2 = spi(exp().eq("c", 30));
same(exp1, exp2);
assertThat(exp1.isSameByBind(exp2)).isTrue();
}
@SuppressWarnings("unchecked")
@Test
void copy() {