Skip to content
Snippets Groups Projects
Commit b1b39161 authored by Denis Arrivault's avatar Denis Arrivault
Browse files

Remove .gradle directory + add the package name for CTest compatibility

parent e67552f7
No related branches found
No related tags found
No related merge requests found
Pipeline #
Showing with 24 additions and 6 deletions
......@@ -7,4 +7,5 @@ build/
*.bkp
*.out
.classpath
/.gradle/
.gradle/
buildCmake/
File deleted
File deleted
File deleted
File deleted
File deleted
File deleted
#Wed Jun 20 13:48:55 CEST 2018
gradle.version=4.7
File deleted
......@@ -9,7 +9,7 @@ jacoco {
version = '1.0.0'
applicationName = "ImmutableComplex"
mainClassName = "Main"
mainClassName = "main.java.Main"
repositories {
jcenter()
......@@ -19,6 +19,20 @@ dependencies {
testCompile "junit:junit:4+"
}
// Here sourceSets is redundant as these are the default gradle paths
sourceSets{
main {
java {
srcDir 'src/main/java'
}
}
test {
java {
srcDir 'src/main/tests'
}
}
}
// Specify the jar manifest to make it executable
jar {
manifest {
......@@ -37,5 +51,6 @@ jacocoTestReport {
}
}
// Finalize test task with jacocoTestReport function
test.finalizedBy(jacocoTestReport)
......@@ -5,7 +5,7 @@ set(CMAKE_JAVA_TARGET_OUTPUT_NAME immutablecomplex-${IMMCOMPLX_VERSION})
# Compile the source files into a jar with a main
add_jar(immutablecomplex java/Complex.java java/Main.java
ENTRY_POINT main.java.Main
ENTRY_POINT main/java/Main
VERSION ${IMMCOMPLX_VERSION})
# Get the jar location
......
/**
* Complex class file
*/
package main.java;
/**
......
package main.java;
public class Main {
......
/**
* Test file for Complex class
*/
package test.java;
import org.junit.Assert;
......@@ -10,6 +11,8 @@ import org.junit.After;
import org.junit.Before;
import org.junit.Test;
import main.java.Complex;
/**
* Junit test case for my immutable complex class.
* @author arrivault
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment