### Question:
DelegatingContentHandlerImpl implements FileContentReferenceHandler { @Override public long putFile(File sourceFile, ContentReference targetContentReference) throws ContentIOException { ContentReferenceHandler delegate = getDelegate(targetContentReference); return delegate.putFile(sourceFile, targetContentReference); }  void setDelegates(List<ContentReferenceHandler> delegates); @Override boolean isContentReferenceSupported(ContentReference contentReference); @Override boolean isContentReferenceExists(ContentReference contentReference); @Override ContentReference createContentReference(String fileName, String mediaType); @Override InputStream getInputStream(ContentReference contentReference, boolean waitForAvailability); @Override long putInputStream(InputStream sourceInputStream, ContentReference targetContentReference); @Override long putFile(File sourceFile, ContentReference targetContentReference); @Override void delete(ContentReference contentReference); @Override boolean isAvailable(); @Override File getFile(ContentReference contentReference, boolean waitForTransfer);  }### Answer:
@Test public void testPutFile() throws Exception { File sourceFile = new File(this.getClass().getResource( "/content-handler-a/file-a-1.txt").toURI()); String targetFolder = "/content-handler-a"; ContentReference targetContentReference = getTextReference(targetFolder); targetContentReference.setUri(targetContentReference.getUri() + "/file-a-3.txt"); delegatingHandler.putFile(sourceFile, targetContentReference); File targetFile = new File(new URI(targetContentReference.getUri())); assertTrue(targetFile.exists()); }