Skip to content

Commit

Permalink
More field mapper test fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
felixbarny committed Nov 25, 2023
1 parent 0727ce6 commit 75acf0c
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,6 @@ protected boolean supportsIgnoreMalformed() {
return false;
}

@Ignore
@Override
public void testMapperBuilderSizeMultiField() {}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,12 @@ protected void registerParameters(ParameterChecker checker) throws IOException {
});
}

@Override
public void testMapperBuilderSizeMultiField() throws IOException {
super.testMapperBuilderSizeMultiField();
assertWarnings("Adding multifields to [geo_shape] mappers has no effect and will be forbidden in future");
}

protected AbstractShapeGeometryFieldType<?> fieldType(Mapper fieldMapper) {
AbstractShapeGeometryFieldMapper<?> shapeFieldMapper = (AbstractShapeGeometryFieldMapper<?>) fieldMapper;
return (AbstractShapeGeometryFieldType<?>) shapeFieldMapper.fieldType();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,12 @@ protected void registerParameters(ParameterChecker checker) throws IOException {
});
}

@Override
public void testMapperBuilderSizeMultiField() throws IOException {
super.testMapperBuilderSizeMultiField();
assertWarnings("Adding multifields to [point] mappers has no effect and will be forbidden in future");
}

public void testAggregationsDocValuesDisabled() throws IOException {
MapperService mapperService = createMapperService(fieldMapping(b -> {
minimalMapping(b);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,12 @@ protected void registerParameters(ParameterChecker checker) throws IOException {
});
}

@Override
public void testMapperBuilderSizeMultiField() throws IOException {
super.testMapperBuilderSizeMultiField();
assertWarnings("Adding multifields to [shape] mappers has no effect and will be forbidden in future");
}

protected AbstractShapeGeometryFieldType<?> fieldType(Mapper fieldMapper) {
AbstractShapeGeometryFieldMapper<?> shapeFieldMapper = (AbstractShapeGeometryFieldMapper<?>) fieldMapper;
return (AbstractShapeGeometryFieldType<?>) shapeFieldMapper.fieldType();
Expand Down

0 comments on commit 75acf0c

Please sign in to comment.