Assert renders template rails




















Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community. Already on GitHub? Sign in to your account. Imported from Lighthouse. I am wondering why testing that a specific layout was used to render a template is dependent on you first testing that a partial is being rendered. From the code:. Notice that the test for the "layout" param elsif options. I have looked through master and have found some tests that seem to be testing this but I am not sure that they are working properly because if you don't pass in the :partial option then it ignores the three assertions that test the layouts collection.

The text was updated successfully, but these errors were encountered:. Sorry, something went wrong. Not pass empty kwargs to ActionPack. Jun 28, Delete render file tests. May 4, Mar 26, Remove unnecessary config about jruby. Aug 11, Require 5. May 17, Update copyright year. Jan 1, Update wording to be explicit on when these methods were removed from…. Feb 18, The view would be rendered , the action called. Try this: controller. Stack Overflow for Teams — Collaborate and share knowledge with a private group.

Create a free Team What is Teams? Collectives on Stack Overflow. Learn more. Rails testing: assert render action Ask Question. Asked 11 years, 7 months ago. Active 1 year, 5 months ago. Viewed 13k times. How can I write a test to assert that the action new is rendered? Improve this question. Add a comment. Active Oldest Votes.



0コメント

  • 1000 / 1000