Created
February 9, 2012 20:44
-
-
Save gdinwiddie/1782945 to your computer and use it in GitHub Desktop.
ant target for running cucumber
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cuke4: | |
[java] Gem::LoadError: Could not find RubyGem cucumber (>= 0) | |
[java] | |
[java] report_activate_error at /Users/gdinwiddie/jruby-1.6.2/lib/ruby/site_ruby/1.8/rubygems.rb:861 | |
[java] activate at /Users/gdinwiddie/jruby-1.6.2/lib/ruby/site_ruby/1.8/rubygems.rb:255 | |
[java] gem at /Users/gdinwiddie/jruby-1.6.2/lib/ruby/site_ruby/1.8/rubygems.rb:1215 | |
[java] (root) at /Users/gdinwiddie/jruby-1.6.2/bin/cucumber:18 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<target name="cuke4" description="Run the cucumber tests"> | |
<java classname="org.jruby.Main" fork="true" failonerror="true"> | |
<classpath> | |
<fileset dir="${jruby.home}/lib"> | |
<include name="*.jar"/><!-- finds 'jruby' --> | |
<include name="**/*.rb" /><!-- doesn't help --> | |
</fileset> | |
<pathelement location="${jruby.home}/lib/ruby/site_ruby/1.8"/><!-- finds 'rubygems' --> | |
<pathelement location="${jruby.home}/lib/ruby/gems/**/lib"/><!-- doesn't help --> | |
<pathelement location="${jruby.home}/lib/ruby/gems/1.8/gems/cucumber-1.0.0/lib"/><!-- doesn't help --> | |
<pathelement location="${jruby.home}/lib/ruby/gems/1.8/gems"/><!-- doesn't help --> | |
<pathelement location="${jruby.home}/lib/ruby/gems/1.8"/><!-- doesn't help --> | |
<pathelement location="${jruby.home}/lib"/><!-- doesn't help --> | |
</classpath> | |
<arg value="-S"/> | |
<arg value="${jruby.home}/bin/cucumber"/> | |
</java> | |
</target> | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
gempath: | |
[java] NameError: uninitialized constant Gem | |
[java] const_missing at org/jruby/RubyModule.java:2569 | |
[java] (root) at -e:1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<target name="gempath" description="display the gem path"> | |
<java classname="org.jruby.Main" fork="true" failonerror="true"> | |
<classpath> | |
<fileset dir="${jruby.home}/lib"> | |
<include name="*.jar"/> | |
</fileset> | |
<pathelement location="${jruby.home}/lib/ruby/site_ruby/1.8"/><!-- finds 'rubygems' --> | |
</classpath> | |
<arg value="-e"/> | |
<arg value="puts Gem.path"/> | |
</java> | |
</target> | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I went back to the simple and obvious start, and, once I found the key to reading the OS environment variables, got it working with the following: