mercredi 25 juillet 2018

How to access session data from test?

The Mojolicious framework states next:

Any aspect of the application (helpers, plugins, routes, etc.) can be introspected from Test::Mojo through the application object.

But when helper, for example, $c->current_user deals with session it fails.

The session data is not available and I can not access it from test:

$t->app->session  # {}

Thus $t->app->current_user fails too.

How to access session data from test?

Aucun commentaire:

Enregistrer un commentaire