parent
7b1c81004c
commit
2ad81ecb40
Binary file not shown.
|
@ -1,6 +1,6 @@
|
||||||
#Tue Sep 16 15:17:56 PDT 2014
|
#Mon Sep 21 11:21:40 PDT 2015
|
||||||
distributionBase=GRADLE_USER_HOME
|
distributionBase=GRADLE_USER_HOME
|
||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
zipStorePath=wrapper/dists
|
zipStorePath=wrapper/dists
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-2.6-bin.zip
|
distributionUrl=https\://services.gradle.org/distributions/gradle-2.7-bin.zip
|
||||||
|
|
|
@ -42,11 +42,6 @@ case "`uname`" in
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
# For Cygwin, ensure paths are in UNIX format before anything is touched.
|
|
||||||
if $cygwin ; then
|
|
||||||
[ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"`
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Attempt to set APP_HOME
|
# Attempt to set APP_HOME
|
||||||
# Resolve links: $0 may be a link
|
# Resolve links: $0 may be a link
|
||||||
PRG="$0"
|
PRG="$0"
|
||||||
|
@ -114,6 +109,7 @@ fi
|
||||||
if $cygwin ; then
|
if $cygwin ; then
|
||||||
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
|
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
|
||||||
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
|
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
|
||||||
|
JAVACMD=`cygpath --unix "$JAVACMD"`
|
||||||
|
|
||||||
# We build the pattern for arguments to be converted via cygpath
|
# We build the pattern for arguments to be converted via cygpath
|
||||||
ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
|
ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
|
||||||
|
|
|
@ -0,0 +1,57 @@
|
||||||
|
package com.github.jrubygradle.storm
|
||||||
|
|
||||||
|
import org.gradle.testkit.runner.GradleRunner
|
||||||
|
import org.gradle.testkit.runner.TaskOutcome
|
||||||
|
import org.gradle.testkit.runner.BuildResult
|
||||||
|
import org.junit.Rule
|
||||||
|
import org.junit.rules.TemporaryFolder
|
||||||
|
import spock.lang.*
|
||||||
|
|
||||||
|
/**
|
||||||
|
*/
|
||||||
|
class JRubyStormLocalIntegrationSpec extends Specification {
|
||||||
|
@Rule
|
||||||
|
final TemporaryFolder testProjectDir = new TemporaryFolder()
|
||||||
|
File buildFile
|
||||||
|
String pluginDependencies
|
||||||
|
|
||||||
|
def setup() {
|
||||||
|
buildFile = testProjectDir.newFile('build.gradle')
|
||||||
|
def pluginClasspathResource = getClass().classLoader.findResource("plugin-classpath.json")
|
||||||
|
|
||||||
|
if (pluginClasspathResource == null) {
|
||||||
|
throw new IllegalStateException("Did not find plugin classpath resource, run `testClasses` build task.")
|
||||||
|
}
|
||||||
|
|
||||||
|
pluginDependencies = pluginClasspathResource.text
|
||||||
|
}
|
||||||
|
|
||||||
|
def "executing runJRubyStorm with no topology should error"() {
|
||||||
|
given:
|
||||||
|
buildFile << """
|
||||||
|
buildscript {
|
||||||
|
dependencies {
|
||||||
|
classpath files(${pluginDependencies})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
apply plugin: 'com.github.jruby-gradle.storm'
|
||||||
|
|
||||||
|
repositories {
|
||||||
|
jcenter()
|
||||||
|
mavenLocal()
|
||||||
|
}
|
||||||
|
|
||||||
|
jrubyStorm {
|
||||||
|
}
|
||||||
|
"""
|
||||||
|
|
||||||
|
when:
|
||||||
|
BuildResult result = GradleRunner.create()
|
||||||
|
.withProjectDir(testProjectDir.root)
|
||||||
|
.withArguments('runJRubyStorm')
|
||||||
|
.build()
|
||||||
|
|
||||||
|
then:
|
||||||
|
result.task(":runJRubyStorm").outcome == TaskOutcome.FAILURE
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue