I have created nested form and want to test it from terminal. How can I Make POST request that creates 2 records – one for parent and one for child – at once?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Pry can help. This is not “testing” but more “debugging” in terminal.
and in the beginning of your action accepting post request, let’s say create;
Browser will not respond but you will get what you want in your terminal.
See this railscast for more info.