An open API service indexing awesome lists of open source software.

https://github.com/pshevche/spokk

Reimagine the Spock testing framework for Kotlin
https://github.com/pshevche/spokk

kotlin spock-framework testing

Last synced: 11 months ago
JSON representation

Reimagine the Spock testing framework for Kotlin

Awesome Lists containing this project

README

          

= Spokk Framework

This repository reimagines the https://github.com/spockframework/spock[Spock] testing framework for Kotlin.
The project is work-in-progress. See the approximate roadmap https://github.com/pshevche/spokk/milestones[here].

== Concept

The framework relies on a Kotlin compiler plugin to support an expressive syntax in your test code.

Example:

[source,kotlin]
----
fun `can add numbers`() {
given("two numbers")
val a = 1
val b = 2

expect("correct sum")
assert(a + b == 3)
}
----

== Modules

* `spokk-compiler-plugin`: contains the implementation of the IR transformer.
* `spokk-core`: testing engine and specification syntax;
* `spokk-gradle-plugin`: Gradle plugin that simplifies the application of the `spokk-compiler-plugin`.
* `spokk-specs`: specifications, implemented using Spokk.