X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=datarouter-node%2Fsrc%2Ftest%2Fjava%2Forg%2Fonap%2Fdmaap%2Fdatarouter%2Fnode%2FDeliveryQueueTest.java;h=6dc334fcabde1d05d4d14af134510eae28b394c5;hb=7704d3079906a4fb51cd58f12d56bd3100fca6b2;hp=9a3d82e50157d0d614bab0553e45379f18db718c;hpb=5775de7b0fc84a29511dc4a1a480c3ab32da2ade;p=dmaap%2Fdatarouter.git diff --git a/datarouter-node/src/test/java/org/onap/dmaap/datarouter/node/DeliveryQueueTest.java b/datarouter-node/src/test/java/org/onap/dmaap/datarouter/node/DeliveryQueueTest.java index 9a3d82e5..6dc334fc 100644 --- a/datarouter-node/src/test/java/org/onap/dmaap/datarouter/node/DeliveryQueueTest.java +++ b/datarouter-node/src/test/java/org/onap/dmaap/datarouter/node/DeliveryQueueTest.java @@ -92,31 +92,14 @@ public class DeliveryQueueTest { files[0] = dirPath + FileName1; } - private void createFolder(String dirName) throws Exception { - String dirPath = dirName; - - File newDirectory = new File(dirPath); - boolean isCreated = newDirectory.mkdirs(); - if (isCreated) { - System.out.println("1. Successfully created directories, path: " + newDirectory.getCanonicalPath()); - } else if (newDirectory.exists()) { - System.out.print("1. Directory path already exist, path: " + newDirectory.getCanonicalPath()); - } else { - System.out.println("1. Unable to create directory"); - } + private void createFolder(String dirName) { + File newDirectory = new File(dirName); + newDirectory.mkdirs(); } private void createFile(String file, String dir) throws Exception { - String FileName = file; - String dirPath = dir; - - File newFile = new File(dirPath + File.separator + FileName); - boolean isCreated = newFile.createNewFile(); - if (isCreated) { - System.out.println("\n2. Successfully created new file, path: " + newFile.getCanonicalPath()); - } else { //File may already exist - System.out.println("\n2. Unable to create new file: " + newFile.getCanonicalPath()); - } + File newFile = new File(dir + File.separator + file); + newFile.createNewFile(); } private void deleteFile(String fileName) {