use of org.apache.sling.jcr.js.nodetypes.downloaddefaultbinary.DownloadDefaultBinaryValueServlet in project sling by apache.
the class DownloadDefaultBinaryValueTest method invokeServletWithEqualPropertyDefs.
private void invokeServletWithEqualPropertyDefs() throws NoSuchNodeTypeException, RepositoryException, ValueFormatException, ServletException, IOException {
NodeType nodeType = mock(NodeType.class);
when(ntManager.getNodeType("ns:ntName")).thenReturn(nodeType);
PropertyDefinition[] propDefs = propDefGenerator.getEqualPropertyDefinitions();
when(nodeType.getPropertyDefinitions()).thenReturn(propDefs);
DownloadDefaultBinaryValueServlet downloadServlet = new DownloadDefaultBinaryValueServlet();
downloadServlet.service(request, response);
}
use of org.apache.sling.jcr.js.nodetypes.downloaddefaultbinary.DownloadDefaultBinaryValueServlet in project sling by apache.
the class DownloadDefaultBinaryValueTest method invokeServletWithDifferentPropertyDefs.
private void invokeServletWithDifferentPropertyDefs() throws NoSuchNodeTypeException, RepositoryException, ValueFormatException, ServletException, IOException {
NodeType nodeType = mock(NodeType.class);
when(ntManager.getNodeType("ns:ntName")).thenReturn(nodeType);
PropertyDefinition[] propDefs = propDefGenerator.getDifferentPropertyDefinitions();
when(nodeType.getPropertyDefinitions()).thenReturn(propDefs);
DownloadDefaultBinaryValueServlet downloadServlet = new DownloadDefaultBinaryValueServlet();
downloadServlet.service(request, response);
}
Aggregations