public static Expression convert(Predicate[] predicates) {
    Expression expression = Expressions.alwaysTrue();
    for (Predicate predicate : predicates) {
      Expression converted = convert(predicate);
      Preconditions.checkArgument(
          converted != null, "Cannot convert Spark predicate to Iceberg expression: %s", predicate);
      expression = Expressions.and(expression, converted);
    }

    return expression;
  }
@Test
  public void testInValuesContainNull() {
    String col = "strCol";
    NamedReference namedReference = FieldReference.apply(col);
    LiteralValue nullValue = new LiteralValue(null, DataTypes.StringType);
    LiteralValue value1 = new LiteralValue("value1", DataTypes.StringType);
    LiteralValue value2 = new LiteralValue("value2", DataTypes.StringType);

    // Values only contains null
    Predicate inNull = new Predicate("IN", expressions(namedReference, nullValue));
    Expression expectedInNull = Expressions.in(col);
    Expression actualInNull = SparkV2Filters.convert(inNull);
    assertEquals(expectedInNull, actualInNull);

    Predicate in = new Predicate("IN", expressions(namedReference, nullValue, value1, value2));
    Expression expectedIn = Expressions.in(col, "value1", "value2");
    Expression actualIn = SparkV2Filters.convert(in);
    assertEquals(expectedIn, actualIn);
  }