@Test
public void testGoodDataFollowedByBadData() throws ParseException {

  Attribute attribute =
      new AttributeImpl(
          FIELD,
          Arrays.asList(
              "POLYGON (( 0 0, 10 0, 10 10, 0 10, 0 0))",
              "POLYGON (( x 5, 15 5, 15 15, 5 15, 5 5))"));
  Optional<String> optionalWkt =
      GeometryUtility.createUnionOfGeometryAttribute(
          wktReader, wktWriter, attribute, new GeometryOperator.Context());
  Geometry actual = wktReader.read(optionalWkt.get()).norm();
  Geometry expected = wktReader.read("POLYGON (( 0 0, 10 0, 10 10, 0 10, 0 0))").norm();
  assertThat(actual, is(expected));
}