I am using jasmine-ajax to mock $.ajax get calls. In my actual code I send some parameters through the data options.
var request = $.ajax("/users", {
data: {id:"1"},
});
but in my tests jasmine.Ajax.requests.mostRecent().url
returns /users?id=1
and jasmine.Ajax.requests.mostRecent().data()
returns {}
. Is there a way to make the url return /users
and data return {id:"1"}
to make my testing life easier?