Skip to content

Commit

Permalink
Added gradle kotlintest build
Browse files Browse the repository at this point in the history
  • Loading branch information
sksamuel committed Jul 21, 2019
1 parent 36837ce commit a385fa2
Show file tree
Hide file tree
Showing 12 changed files with 65 additions and 43 deletions.
5 changes: 5 additions & 0 deletions .editorconfig
Expand Up @@ -7,3 +7,8 @@ indent_size = 2

trim_trailing_whitespace = true
insert_final_newline = true

# 4 space indentation for gradle
[build.gradle]
indent_style = space
indent_size = 4
25 changes: 16 additions & 9 deletions .travis.yml
@@ -1,22 +1,29 @@
language: java

jdk:
- openjdk11
- openjdk11

sudo: false

before_cache:
- rm -f $HOME/.gradle/caches/modules-2/modules-2.lock
- rm -fr $HOME/.gradle/caches/*/plugin-resolution/
- rm -f $HOME/.gradle/caches/modules-2/modules-2.lock
- rm -fr $HOME/.gradle/caches/*/plugin-resolution/

cache:
directories:
- "$HOME/.gradle/caches/"
- "$HOME/.gradle/wrapper/"
- "$HOME/.m2/repository/"
- "$HOME/.gradle/caches/"
- "$HOME/.gradle/wrapper/"
- "$HOME/.m2/repository/"

install: "/bin/true"

script: "./gradlew test"

after_success: "./snapshot_deploy.sh"
jobs:
include:
- stage: test
name: "junit gradle plugin"
script: "./gradlew test"
- stage: test
name: "kotlintest gradle plugin"
script: "./gradlew kotlintest"
- stage: deploy
script: "./snapshot_deploy.sh"
7 changes: 4 additions & 3 deletions build.gradle
Expand Up @@ -9,7 +9,7 @@ buildscript {
repositories {
mavenCentral()
}

dependencies {
classpath "org.jetbrains.dokka:dokka-gradle-plugin:$dokkaVersion"
}
Expand All @@ -22,6 +22,7 @@ plugins {
id 'maven-publish'
id 'signing'
id 'net.researchgate.release' version '2.8.0'
id "io.kotlintest" version "1.1.0"
}

allprojects {
Expand All @@ -37,7 +38,7 @@ allprojects {
group = "io.kotlintest"

if (isTravis) {
version "3.4.0." + travisBuildNumber + "-SNAPSHOT"
version "3.4.1." + travisBuildNumber + "-SNAPSHOT"
}

release {
Expand All @@ -56,4 +57,4 @@ dependencies {

project(":") {
publish.enabled = false
}
}
Expand Up @@ -4,6 +4,7 @@ plugins {
id 'java-library'
id 'maven-publish'
id 'signing'
id "io.kotlintest"
}

apply plugin: 'kotlin-kapt'
Expand All @@ -30,4 +31,4 @@ compileKotlin {
}


apply from: '../../publish.gradle'
apply from: '../../publish.gradle'
Expand Up @@ -8,6 +8,7 @@ plugins {
id 'java-library'
id 'maven-publish'
id 'signing'
id "io.kotlintest"
}

repositories {
Expand All @@ -23,4 +24,4 @@ dependencies {
testCompile project(':kotlintest-runner:kotlintest-runner-junit5')
}

apply from: '../../publish.gradle'
apply from: '../../publish.gradle'
Expand Up @@ -8,6 +8,7 @@ plugins {
id 'java-library'
id 'maven-publish'
id 'signing'
id "io.kotlintest"
}

repositories {
Expand All @@ -32,4 +33,4 @@ compileTestKotlin {
kotlinOptions.jvmTarget = "1.8"
}

apply from: '../../publish.gradle'
apply from: '../../publish.gradle'
5 changes: 3 additions & 2 deletions kotlintest-tests/kotlintest-tests-core/build.gradle
Expand Up @@ -4,7 +4,7 @@ buildscript {
mavenLocal()
}
dependencies {
// classpath "io.kotlintest:kotlintest-gradle-plugin:1.0.3-LOCAL"
// classpath "io.kotlintest:kotlintest-gradle-plugin:1.0.3-LOCAL"
}
}

Expand All @@ -14,6 +14,7 @@ plugins {
id 'java-library'
id 'maven-publish'
id 'signing'
id "io.kotlintest"
}

//apply plugin: "io.kotlintest"
Expand Down Expand Up @@ -51,4 +52,4 @@ test {
}
}

publish.enabled = false
publish.enabled = false
Expand Up @@ -4,6 +4,7 @@ plugins {
id 'java-library'
id 'maven-publish'
id 'signing'
id "io.kotlintest"
}

dependencies {
Expand Down
Expand Up @@ -4,6 +4,7 @@ plugins {
id 'java-library'
id 'maven-publish'
id 'signing'
id "io.kotlintest"
}

dependencies {
Expand Down
1 change: 1 addition & 0 deletions kotlintest-tests/kotlintest-tests-junit5/build.gradle
Expand Up @@ -4,6 +4,7 @@ plugins {
id 'java-library'
id 'maven-publish'
id 'signing'
id "io.kotlintest"
}

dependencies {
Expand Down
1 change: 1 addition & 0 deletions kotlintest-tests/kotlintest-tests-parallelism/build.gradle
Expand Up @@ -4,6 +4,7 @@ plugins {
id 'java-library'
id 'maven-publish'
id 'signing'
id "io.kotlintest"
}

dependencies {
Expand Down
53 changes: 27 additions & 26 deletions kotlintest-tests/kotlintest-tests-timeout/build.gradle
@@ -1,45 +1,46 @@
buildscript {
repositories {
mavenCentral()
mavenLocal()
}
repositories {
mavenCentral()
mavenLocal()
}
}

plugins {
id 'java'
id 'org.jetbrains.kotlin.jvm'
id 'java-library'
id 'maven-publish'
id 'signing'
id 'java'
id 'org.jetbrains.kotlin.jvm'
id 'java-library'
id 'maven-publish'
id 'signing'
id "io.kotlintest"
}

repositories {
mavenCentral()
mavenLocal()
mavenCentral()
mavenLocal()
}

dependencies {
testImplementation project(':kotlintest-core')
testImplementation project(':kotlintest-assertions')
testImplementation project(':kotlintest-runner:kotlintest-runner-junit5')
testImplementation 'org.apache.logging.log4j:log4j-slf4j-impl:2.11.2'
testImplementation "com.nhaarman:mockito-kotlin:1.6.0"
testImplementation 'org.mockito:mockito-core:2.24.0'
testImplementation project(':kotlintest-core')
testImplementation project(':kotlintest-assertions')
testImplementation project(':kotlintest-runner:kotlintest-runner-junit5')
testImplementation 'org.apache.logging.log4j:log4j-slf4j-impl:2.11.2'
testImplementation "com.nhaarman:mockito-kotlin:1.6.0"
testImplementation 'org.mockito:mockito-core:2.24.0'
}

test {
useJUnitPlatform()
useJUnitPlatform()

// show standard out and standard error of the test JVM(s) on the console
testLogging.showStandardStreams = true
// show standard out and standard error of the test JVM(s) on the console
testLogging.showStandardStreams = true

// Always run tests, even when nothing changed.
dependsOn 'cleanTest'
// Always run tests, even when nothing changed.
dependsOn 'cleanTest'

testLogging {
events "PASSED", "FAILED", "SKIPPED", "STANDARD_OUT", "STANDARD_ERROR"
exceptionFormat = 'full'
}
testLogging {
events "PASSED", "FAILED", "SKIPPED", "STANDARD_OUT", "STANDARD_ERROR"
exceptionFormat = 'full'
}
}

publish.enabled = false

0 comments on commit a385fa2

Please sign in to comment.