Form submit with Jasmine

Skip to first unread message

Rob Conaway

Jan 19, 2011, 9:59:29 AM1/19/11
to Jasmine
Is there a practical way to have Jasmine drive a test which includes a
form submit? The obvious problem is that when you submit a form the
new page replaces the existing page, including the test runner. Is
there a solution involving separate windows, perhaps?

Jeff Deville

Jan 19, 2011, 11:22:37 AM1/19/11
Given that you're mocking the html, and not pulling it from a server, do you care what is happening after the submission, or are you just trying to verify that the form was submitted?  If the former, I don't know how you'd do this anyway, because there's no where to post the data to.  If the latter, you can hook into the form submission event, and spy on it, and then mock it to return null. 

You received this message because you are subscribed to the Google Groups "Jasmine" group.
To post to this group, send email to
To unsubscribe from this group, send email to
For more options, visit this group at

Pranjulya Bajpai

May 17, 2016, 4:23:37 PM5/17/16
to Jasmine,
HI just test whether the given form has successfully submitted or not, there is no possible way to test what is happening after the submission.
Reply all
Reply to author
0 new messages