### Question:
MultipartPart implements Closeable { protected void visitPreContent(PartVisitor visitor) { visitStart(visitor); visitDispositionHeader(visitor); visitContentTypeHeader(visitor); visitTransferEncodingHeader(visitor); visitContentIdHeader(visitor); visitCustomHeaders(visitor); visitEndOfHeaders(visitor); } MultipartPart(T part, byte[] boundary); long length(); MultipartState getState(); boolean isTargetSlow(); long transferTo(ByteBuf target); long transferTo(WritableByteChannel target); @Override void close();  }### Answer:
@Test public void testVisitPreContent() { TestFileLikePart fileLikePart = new TestFileLikePart("Name", "application/test", UTF_8, "contentId", "transferEncoding", "fileName"); fileLikePart.addCustomHeader("custom-header", "header-value"); try (TestMultipartPart multipartPart = new TestMultipartPart(fileLikePart, new byte[0])) { CounterPartVisitor counterVisitor = new CounterPartVisitor(); multipartPart.visitPreContent(counterVisitor); assertEquals(counterVisitor.getCount(), 216, "CounterPartVisitor count for visitPreContent should " + "be equal to the sum of the lengths of precontent"); } }