add capybara; change ajax response to json