How do I create an authenticated user session in system tests?

I am using rails 8 w/ built-in authentication. How can I create authenticated session for use with system tests? Devise has some integration test helpers. Are there such things for built-in generated authentication in rails?

If not, should I stick to using fill_ins and click_ons, in setup methods?

1 Like

I use a login_as(user) method that uses click_on, fill_in, etc. complete the login.

1 Like

Thanks for the reply. Yeah, that’s what I ended up with. login_as in an application test case.