aboutsummaryrefslogtreecommitdiff
path: root/src/test/groovy/frege/gradle/FregeBasePluginTest.groovy
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/groovy/frege/gradle/FregeBasePluginTest.groovy')
-rw-r--r--src/test/groovy/frege/gradle/FregeBasePluginTest.groovy29
1 files changed, 29 insertions, 0 deletions
diff --git a/src/test/groovy/frege/gradle/FregeBasePluginTest.groovy b/src/test/groovy/frege/gradle/FregeBasePluginTest.groovy
new file mode 100644
index 0000000..ebdb7d3
--- /dev/null
+++ b/src/test/groovy/frege/gradle/FregeBasePluginTest.groovy
@@ -0,0 +1,29 @@
+package frege.gradle
+import org.gradle.api.Project
+import org.gradle.testfixtures.ProjectBuilder
+import spock.lang.Specification
+
+public class FregeBasePluginTest extends Specification {
+
+ Project project = ProjectBuilder.builder().build()
+
+ def setup(){
+ when:
+ project.plugins.apply(FregeBasePlugin)
+ }
+
+ def "adds frege extension"(){
+ expect:
+ project.getExtensions().getByName(FregeBasePlugin.EXTENSION_NAME) != null
+ }
+
+ def "applies java base plugin"(){
+ expect:
+ project.pluginManager.hasPlugin("java-base")
+ }
+
+ def "can be identified by id"(){
+ expect:
+ project.pluginManager.hasPlugin("org.frege-lang.base")
+ }
+} \ No newline at end of file