Description
When calling struct.put() with an invalid value, the error message should include the field name.
@Test public void testPutIncludesFieldName() { final String fieldName = "fieldName"; Schema testSchema = SchemaBuilder.struct() .field(fieldName, Schema.STRING_SCHEMA); Struct struct = new Struct(testSchema); try { struct.put(fieldName, null); } catch (DataException ex) { assertEquals( "Invalid value: null used for required field: \"fieldName\", schema type: STRING", ex.getMessage() ); } }