Questions tagged [rspec-expectations]

rspec-expectations is a module of the RSpec BDD suite that provides a readable API to express expected test outcomes, usable with other tools such as Cucumber as well as with RSpec.

rspec-expectations is a module of the RSpec BDD suite that provides a readable API to express expected test outcomes, usable with other tools such as Cucumber as well as with RSpec. It is implemented as a Ruby gem.

Instructions for how to use rspec-expectations with Cucumber can be found on Cucumber's Github wiki.

35 questions
0
votes
1 answer

Validate table for empty cells

Could you help to advise some script to validate a table cells for empty values? I need to validate that there are no empty cells in table. tableFG = page.table(:id => 'FinancialsGrid') tableFG.rows.each do |row| row.cells.each do |cell| …
0
votes
3 answers

How to get text of selected option from select list without [ ] brackets

I use next command to get a text of selected option in select list: @sltedStudy=page.select_list_element(:id => 'cntrStudy', :frame => frame).selected_options(&:text) But when I try to compare values: expect(page.cell_element(:xpath =>…
0
votes
1 answer

rspec-expectations-2.99.0/lib/rspec/matchers/built_in/raise_error.rb:5: uninitialized constant RSpec::Matchers::BuiltIn::RaiseError::MatchAliases

Output error from running rspec in my cookbook directory. C:\Users\a540409\IdeaProjects\stores-v2\chef>bundle exec rspec C:/Ruby193/lib/ruby/gems/1.9.1/gems/rspec-expectations-2.99.0/lib/rspec/matchers/built_in/raise_error.rb:5:in…
0
votes
1 answer

RSpec::Expectations::ExpectationNotMetError in cucumber routing issue

I started working on BDD through cucumber. (using Rails-3, gem 'cucumber-rails') I want to redirect to user profile page (/users/id) when successful login. I defined in controller as (redirect_to user_path(@user)) and the same thing I defined in…
RohitPorwal
  • 1,045
  • 15
  • 23
-1
votes
2 answers

Rspec - expecting one among specific outputs

Working on rspec(2.14.1), rspec-core (2.14.8) & rspec-expectations(2.14.5) versions Need to expect one of two specific outputs. Tried below statements and got respective errors, expect(fruit).should be_in('Apple','Mango') Error NoMethodError:…
mon23
  • 1
1 2
3