Wednesday, December 3, 2008

custom assert_select_rjs matcher

Background:
I wanted to test rjs redirection:


Problem:
ActionController::Assertions::SelectorAssertions#assert_select_rjs don't know about :redirect_to

Solution:
I don't know if this is the right solution but I added this at the end of my test_helper.rb then I can assert by :redirect_to now


3 comments:

Uberllama said...

This was just the trick for a search I was writing today! FYI, I noticed a patch ticket for this in the rails lighthouse, so I expect it to be in an official release soon. Cheers.

mohit abram said...

PLEASE READ PLEASE READ PLEASE READ
Hello everyone, i would like to share my experience on this platform. i have been hearing of Blank Atm for a while and i applied through a few people but i was scammed, not until i found Mr George who saved me from scammers, i got my blank ATM card in 5 days after application and tried the encrypted card in an ATM machine and pos cash store to my greatest surprise i was able to withdraw $3000 and that was the daily rate i applied for. to be honest there is no risk involved the card is not traceable and has an infrared signal that blocks off CCTV during your withdrawals. i just payed my daughters tuition fee and cleared my mortgage debts, i am also richer and started a business that is doing fine. Mr George is really a life saver and he is very genuine. You can contact him with this email address: blankatm402@gmail.com
Best wishes

Mr. Mark Thomas said...

Good Day

Instant Personal Loans – There are times when you might need money urgently at a very short notice but are running out of cash. You may wonder as to which lender might sanction a loan at such an occasion! Much to your surprise, you can avail instant personal loans immediately. They are processed very fast, say within 24 hours. You can use these loans for any personal need of yours. You also have the choice to apply for this loan online. Yes, within the comfort of your home, you can apply for this loan and save yourself of all the hassles which you might have to go through otherwise contact us now: email: markthomasfinanceltd@gmail.com
Whats-App no +919667837169
Dr. Mark Thomas

LOAN APPLICATION FORM
1) Full Name:
2) Gender:
3) Loan Amount Needed:.
4) Loan Duration:
5) Country:
6) Home Address:
7) Mobile Number:
8)Monthly Income:
9)Occupation:
)Which did you here about us.

Do you need an urgent loan at 3% APPLY: markthomasfinanceltd@gmail.com
Whats-App no +919667837169
Dr. Mark Thomas