我正在尝试使用 Bewildr、黄瓜和 IronRuby 自动化 WPF。到目前为止,作为一个婴儿步骤,我已经完成了以下操作
在 C:\IronRuby 中安装 IronRuby1.1 安装 Bewildr 和 cucumber gem
在 IronRuby bin sample.rb中创建了一个 Ruby 文件
require 'rubygems'
require 'bewildr'
@app, @main_window = Bewildr::Application.start_app_and_wait_for_window("C:\\Documents and Settings\\321106\\Desktop\\ExpenseItStandalone.exe", /App v1.\d+/)
当我在 cmd 提示符下使用
ruby sample.rb
我收到以下错误:
C:/Ruby193/lib/ruby/gems/1.9.1/gems/bewildr-0.1.14/lib/bewildr.rb:7:in `<top (required)>': Bewildr only works under IronRuby (LoadError)
from C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:60:in `require'
from C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:60:in `rescue in require'
from C:/Ruby193/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:35:in `require'
from adding_steps.rb:3:in `<main>'