de.joshuagleitze:atrium-gradle-testkit-logic

Atrium assertions for testing Gradle plugins.

Лицензия

Лицензия

MIT
Категории

Категории

Gradle Компиляция и сборка
Группа

Группа

de.joshuagleitze
Идентификатор

Идентификатор

atrium-gradle-testkit-logic
Последняя версия

Последняя версия

1.0.1
Дата

Дата

Тип

Тип

pom.sha512
Описание

Описание

de.joshuagleitze:atrium-gradle-testkit-logic
Atrium assertions for testing Gradle plugins.
Ссылка на сайт

Ссылка на сайт

https://github.com/jGleitz/atrium-gradle-testkit
Система контроля версий

Система контроля версий

https://github.com/jGleitz/atrium-gradle-testkit

Скачать atrium-gradle-testkit-logic

Зависимости

compile (1)

Идентификатор библиотеки Тип Версия
org.jetbrains.kotlin : kotlin-stdlib-jdk8 jar 1.4.10

runtime (3)

Идентификатор библиотеки Тип Версия
de.joshuagleitze : atrium-gradle-testkit-translation-en jar 1.0.1
ch.tutteli.atrium : atrium-core-api jar 0.15.0
ch.tutteli.atrium : atrium-logic jar 0.15.0

Модули Проекта

Данный проект не имеет модулей.

atrium-gradle-testkit CI Status Maven Central

Atrium assertions to test Gradle plugins with TestKit.

👉 Documentation of all assertions

Example

Here is how you can use this library to test Gradle plugins. The example uses Spek with spek-testfiles. You can see the whole example in the example-project folder.

object KotlinPluginSpek: Spek({
	val testFiles = testFiles()
	val projectDir by memoized(SCOPE) { testFiles.createDirectory("testProject") }

	describe("run") {
		it("compiles the Kotlin code and runs it") {
			val runResult = GradleRunner.create()
				.forwardOutput()
				.withProjectDir(projectDir.toFile())
				.withArguments("run")
				.build()

			expect(runResult) {
				task(":compileKotlin").wasSuccessful()
				task(":classes").wasInvoked()
				output.contains("Hello World!")
			}
		}
	}

	beforeGroup {
		/* set up the gradle project */
	}
})

Contributions welcome

All contributions (no matter if small) are always welcome.

Applying the YAGNI principle, this library only provides the functionality that was needed by someone. If you have any idea for how this library could be more useful, please create an issue! Ideas for improvements are always welcome.

Версии библиотеки

Версия
1.0.1
1.0.0