small medium large xlarge

Generic-user-small
01 Jul 2017, 22:02
Akai Bukai (2 posts)

Hi,

In the page 249 (B3.0) we need to add the login step to our tests. The listing is about a class ActionDispatch::IntegrationTest.

However, the test_helper file have a class ActiveSupport::TestCase. Since there are no more details about this I had some hard time to figure out that this class is indeed added, thus having two classes.

First question, how we can learn what kind of class we can (or should) add to which part of test or any other part of the framework?

Also, the paragraph after the listing states that

Note that the setup() method will call login_as() only if session is defined..

How does this work? I mean where that behavior is defined?

Thank you for the clarifications.

You must be logged in to comment