plugin.src.test.groovy.org.gradle.GreetingPluginTest.groovy Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of gradle-api Show documentation
Show all versions of gradle-api Show documentation
Gradle 6.9.1 API redistribution.
package org.gradle
import org.junit.Test
import org.gradle.testfixtures.ProjectBuilder
import org.gradle.api.Project
import static org.junit.Assert.*
// START SNIPPET test-plugin
class GreetingPluginTest {
@Test
public void greeterPluginAddsGreetingTaskToProject() {
Project project = ProjectBuilder.builder().build()
project.pluginManager.apply 'org.samples.greeting'
assertTrue(project.tasks.hello instanceof GreetingTask)
}
}
// END SNIPPET test-plugin
© 2015 - 2025 Weber Informatics LLC | Privacy Policy