All Downloads are FREE. Search and download functionalities are using the official Maven repository.

application.test.MonochromePrinter.kt Maven / Gradle / Ivy

There is a newer version: 1.3.39
Show newest version
package application.test

import org.junit.platform.engine.TestExecutionResult
import org.junit.platform.launcher.TestIdentifier

class MonochromePrinter: ContractExecutionPrinter {
    override fun printFinalSummary(testSummary: TestSummary) {
        println(testSummary.message)
        println()
        println("Executed at ${currentDateAndTime()}")
    }

    override fun printTestSummary(testIdentifier: TestIdentifier?, testExecutionResult: TestExecutionResult?) {
        println(testStatusMessage(testIdentifier, testExecutionResult))
    }

    override fun printFailureTitle(failures: String) {
        println(failures)
    }
}

fun currentDateAndTime(): String {
    return java.time.LocalDateTime.now().toString()
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy