Compare commits

..

No commits in common. "03fb0164c259a3a5d043bf55f42139292a4e0c9c" and "d005944874649495f6f6eed17b0d13f92a8bb222" have entirely different histories.

3 changed files with 16 additions and 36 deletions

View file

@ -1,7 +1,7 @@
package com.example;
import rife.bld.BaseProject;
import rife.bld.BuildCommand;
import rife.bld.Project;
import rife.bld.extension.CompileKotlinOperation;
import rife.bld.extension.CompileKotlinOptions;
import rife.bld.extension.dokka.DokkaOperation;
@ -19,9 +19,8 @@ import java.util.logging.Logger;
import static rife.bld.dependencies.Repository.*;
import static rife.bld.dependencies.Scope.compile;
import static rife.bld.dependencies.Scope.test;
public class ExampleBuild extends Project {
public class ExampleBuild extends BaseProject {
public ExampleBuild() {
pkg = "com.example";
name = "Example";
@ -35,10 +34,8 @@ public class ExampleBuild extends Project {
scope(compile)
.include(dependency("org.jetbrains.kotlin", "kotlin-stdlib", version(1, 9, 20)));
scope(test)
.include(dependency("org.jetbrains.kotlin:kotlin-test-junit5:1.9.20"))
.include(dependency("org.junit.jupiter", "junit-jupiter", version(5, 10, 1)))
.include(dependency("org.junit.platform", "junit-platform-console-standalone", version(1, 10, 1)));
testOperation().mainClass("com.example.ExampleTest");
}
public static void main(String[] args) {

View file

@ -1,11 +1,18 @@
package com.example
import kotlin.test.Test
import kotlin.test.assertEquals
class ExampleTest {
@Test
fun verifyHello() {
assertEquals("Hello World!", Example().message)
if ("Hello World!" != Example().message) {
throw AssertionError()
} else {
println("Succeeded")
}
}
companion object {
@JvmStatic
fun main(args: Array<String>) {
ExampleTest().verifyHello()
}
}
}

View file

@ -307,18 +307,6 @@ public class CompileKotlinOptions {
return this;
}
/**
* Specify the target version of the generated JVM bytecode.
*
* @param version the target version
* @return this class insance
* @see #jdkRelease(String)
*/
public CompileKotlinOptions jdkRelease(int version) {
jdkRelease_ = String.valueOf(version);
return this;
}
/**
* Specify the target version of the generated JVM bytecode.
* Possible values are 1.8, 9, 10, ..., 21. The default value is 1.8.
@ -331,18 +319,6 @@ public class CompileKotlinOptions {
return this;
}
/**
* Specify the target version of the generated JVM bytecode.
*
* @param target the target version
* @return this class instance
* @see #jvmTarget(String)
*/
public CompileKotlinOptions jvmTarget(int target) {
jvmTarget_ = String.valueOf(target);
return this;
}
/**
* Enable verbose logging output which includes details of the compilation process.
*