views:

242

answers:

3

I'm using IronRuby 0.9.1 and cucumber 0.4.0. I also have MRI 1.8 installed.

I've created the following wrapper script (icucumber.bat) to run cucumber on IronRuby

@ECHO OFF
REM This is to tell IronRuby where to find gems.
SET GEM_PATH=c:\ruby\lib\ruby\gems\1.8
@"C:\ironruby\bin\ir.exe" "c:\ruby\bin\cucumber" %*

Navigating to cucumber-0.4.0\examples\i18n\en and running:

cucumber features  // takes about 4 seconds to complete
icucumber features // takes about 30 seconds to complete

Cucumber on IR is MUCH slower to initialize, so it seems. Is this typical? Or did I set this up incorrectly?

+1  A: 

For me it takes about 10 seconds to start cucumber. Startup time is currently problematic in IronRuby but the team is working on it. You can find comfort in the fact that IronRuby, after it starts, works much faster than MRI (some say twice as fast!).

Shay.

Shay Friedman
+1  A: 

We have experienced the same behavior. This is probably related to a bug in IronRuby, because as far as I've heard, it was faster with the previous versions.

Partly because of this problem, and also because of others, like the build integration issues we have launched an open-source project, SpecFlow, that aims to provide better cucumber experience for the .NET users.

Gaspar Nagy
A: 

It helps a lot if you ngen the IronRuby assemblies.

Whenever I install a new version of IronRuby, I always run this in a command prompt:

cd [the ironruby bin dir]
for %i in (*.dll) do C:\Windows\Microsoft.NET\Framework\v2.0.50727\ngen.exe %i
C:\Windows\Microsoft.NET\Framework\v2.0.50727\ngen.exe ir.exe
Orion Edwards