#397 new

Case sensitive search fails while using Webrat with rspec model tests

Reported by Installero | October 20th, 2010 @ 02:11 PM

I want to use

page.should have_xpath ('//TKKPG')


page.should have_tag('TKKPG')

while testing xml output of some model method.

When I'm using webrat I get case insensitive output, so there are no TKKPG tags, so it fails:

1) Order acquiring to_acquiring_xml should return valid xml for order
Failure/Error: xml.should have_selector('TKKPG')
expected following output to contain a <TKKPG/> tag:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
 <?xml version="1.0" encoding="UTF-8"?><html><body><tkkpg><request></request></tkkpg></body></html>
 # ./spec/models/order_spec.rb:596

Comments and changes to this ticket

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

Ruby Acceptance Testing for Web applications.

Shared Ticket Bins

People watching this ticket