Mentions légales du service

Skip to content
Snippets Groups Projects
Commit ffcff757 authored by Achraf Achkari's avatar Achraf Achkari
Browse files

Fix Pipeline Jacoco

parent 585b9f57
No related branches found
No related tags found
2 merge requests!2Release GOC,!1Release GOC
Pipeline #328936 failed
...@@ -200,6 +200,8 @@ public class HL7Templates2GOC { ...@@ -200,6 +200,8 @@ public class HL7Templates2GOC {
try { try {
parser.parseArgument(args); parser.parseArgument(args);
addSubDirectoryToOutput("/validator");
// initialize log variable // initialize log variable
initLog(); initLog();
GOCLogger gocLogger = new GOCLoggerImpl(getWorkspaceRoot(getOutputFile()), generationDate); GOCLogger gocLogger = new GOCLoggerImpl(getWorkspaceRoot(getOutputFile()), generationDate);
...@@ -211,10 +213,7 @@ public class HL7Templates2GOC { ...@@ -211,10 +213,7 @@ public class HL7Templates2GOC {
environementChecker.checkMVNPath(mvnExecPath,processExecutor); environementChecker.checkMVNPath(mvnExecPath,processExecutor);
environementChecker.checkJavaVersion(); environementChecker.checkJavaVersion();
if (this.bbr == null || this.outputFile == null) {
log.info(HL7Templates2GOC.DOCUMENTATION_STRING);
return;
}
HL7TEMP_RESOURCES_PATH = HL7TEMP_RESOURCES_PATH==null? HL7TEMP_RESOURCES_PATH = HL7TEMP_RESOURCES_PATH==null?
getWorkspaceRoot(outputFile)+"/hl7templates-resources":HL7TEMP_RESOURCES_PATH; getWorkspaceRoot(outputFile)+"/hl7templates-resources":HL7TEMP_RESOURCES_PATH;
...@@ -265,6 +264,19 @@ public class HL7Templates2GOC { ...@@ -265,6 +264,19 @@ public class HL7Templates2GOC {
return getOutputFile().substring(0, getOutputFile().lastIndexOf("/") + 1); return getOutputFile().substring(0, getOutputFile().lastIndexOf("/") + 1);
} }
/**
* Method to add sub-directories to the provided output path
* To encapsulate validator and logs in one directory
* Provide empty string to use the old behavior
* @param subDirectory sub-directorie(s), started with '/'
*/
private void addSubDirectoryToOutput(String subDirectory){
if(subDirectory == null){
subDirectory = "";
}
this.outputFile = this.outputFile + subDirectory;
}
public static void main(String[] args) { public static void main(String[] args) {
HL7Templates2GOC hl7Templates2GOC = new HL7Templates2GOC(); HL7Templates2GOC hl7Templates2GOC = new HL7Templates2GOC();
hl7Templates2GOC.execute(args); hl7Templates2GOC.execute(args);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment