MultipartConfigElement { public long getMaxRequestSize() { return this.maxRequestSize; } MultipartConfigElement(String location);  MultipartConfigElement(String location, long maxFileSize, long maxRequestSize, int fileSizeThreshold);  MultipartConfigElement(MultipartConfig annotation); int getFileSizeThreshold(); String getLocation(); long getMaxFileSize(); long getMaxRequestSize();  }
@Test void testGetMaxRequestSize() { MultipartConfigElement element = new MultipartConfigElement("location", 0, 1000, 0); assertEquals(1000, element.getMaxRequestSize()); }
@Test void testGetMaxRequestSize2() { MultipartConfigElement element = new MultipartConfigElement(new MultipartConfig() { @Override public int fileSizeThreshold() { return 1000; } @Override public String location() { return ""; } @Override public long maxFileSize() { return 1000; } @Override public long maxRequestSize() { return 1000; } @Override public Class<? extends Annotation> annotationType() { throw new UnsupportedOperationException("Not supported yet."); } }); assertEquals(1000, element.getMaxRequestSize()); }