1

我正在使用 IronRuby 0.9.1 和黄瓜 0.4.0。我还安装了 MRI 1.8。

我创建了以下包装脚本 (icucumber.bat) 来在 IronRuby 上运行 cucumber

@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" %* 

导航到 cucumber-0.4.0\examples\i18n\en 并运行:

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

IR 上的 Cucumber 初始化速度要慢得多,所以看起来。这是典型的吗?还是我设置不正确?

4

3 回答 3

2

对我来说,开始黄瓜大约需要 10 秒。IronRuby 的启动时间目前存在问题,但团队正在努力解决这个问题。IronRuby 在启动后的运行速度比 MRI 快得多(有人说是 MRI 的两倍!),这让您感到欣慰。

谢伊。

于 2009-10-14T08:20:29.957 回答
1

如果您生成 IronRuby 程序集,它会很有帮助。

每当我安装 IronRuby 的新版本时,我总是在命令提示符下运行它:

cd [ironruby bin 目录]
对于 (*.dll) 中的 %i 执行 C:\Windows\Microsoft.NET\Framework\v2.0.50727\ngen.exe %i
C:\Windows\Microsoft.NET\Framework\v2.0.50727\ngen.exe ir.exe
于 2009-11-03T22:31:19.723 回答
1

我们经历过同样的行为。这可能与 IronRuby 中的一个错误有关,因为据我所知,以前的版本更快。

部分是因为这个问题,也因为其他问题,比如构建集成问题,我们推出了一个开源项目SpecFlow,旨在为 .NET 用户提供更好的黄瓜体验。

于 2009-11-03T09:08:26.163 回答