网络老鼠 +野科切 + CSS 选择器 +空格=噩梦
我需要使用 Cucumber/Webrat 测试此按钮的存在: <%=submit_tag 'Get it'%> 但是当我使用此自定义步骤时: And I should see a button with a val…
黄瓜和黄瓜webrat,从单选按钮列表中选择
我试图让 webrat 使用黄瓜从列表中选择一个单选按钮。 我有这样的场景: Scenario: Update an existing article Given I have an article with title …
使用 Webrat 检查选择框是否具有某些选项
如何使用 Webrat 检查选择框是否具有列为选项的某些值?我目前有 field_named(field).value.should contains(value) 但仅传递第一个选定的值,而不传…
Cucumber/Webrat 不遵循redirect_to
我正在运行 Rails 3.0.0、rspec-rails 2.0.0.beta.20、webrat 0.7.2.beta.1、cucumber-rails 0.3.2 我有这样的场景: Scenario: Given I am on the ne…
Webrat (web_steps.rb) 未使用
当我执行以下黄瓜脚本时: Feature: Manage Customers In order to store customers As a user I want to create and manage customers Scenario Outl…
如何用 Cucumber 测试某个单词是否是链接?
我想要这个自定义步骤: Then I should see the link 'foo' 和他的相反: But I should not see the link 'foo' 在页面中我可以有类似的内容: lorem …
未定义的方法“find_link”对于 #(无方法错误)
Rspec 显然讨厌我。我有点讨厌他了。 #features/step_definitions/custom_steps.rb Then /^I should see the link "([^\"]*)"$/ do |linked_text| fin…
authlogic flash[:notice] 没有出现在 Cucumber Webrat 步骤中
我正在使用 Cucumber 运行 BDD 步骤来实现我的自动逻辑登录行为。 Scenario: log in Given a registered user: "[email protected]" with passwor…
Webrat / Cucumber Matcher - 测试内容与链接的匹配
目前我有一个喜欢/不喜欢投票功能,以以下格式输出: 喜欢 (#) dislike (#) 其中喜欢和不喜欢是可点击的链接,用于更新喜欢/不喜欢投票的总数(由 (#)…
Webrat 和 Rails:在 click_button 之后使用 assert_contain 会给我“您正在被重定向”
我正在使用 webrat 为 Rails 应用程序编写集成测试。填写表格后,用户按下提交并创建一个帐户。 click_button "Submit" assert_contain "Your Account…
当你在cucumber下使用WebRat点击按钮时会发生什么
我正在尝试登录 Java Web 应用程序。 登录页面具有以下 html : <html> <head><title>Login Page</title></head> <body onload…
Webrat select_date 选择器失败
步骤文件中的代码: select_date user.date_of_birth, :from => "Date of birth" 选择器失败 When I register with valid user credentials # featu…
如何测试需要输入安全短语中的两个随机字符的表单?
我需要测试一个两阶段登录系统,该系统首先询问您的电子邮件地址和密码,然后向用户提供两个包含 [a-zA-Z0-9] 的选择列表。下拉菜单旁边的标签采用“…
如何在 rspec 中测试 css 属性?
我正在使用 Rails 的 tabnav 插件,我想使用 rpsec 来确保它正确突出显示。 describe 'account navigation links' do it 'should have account settin…