Functional test cases using Helpers.route, creating a new Http.Context even if there is one existed

9 views
Skip to first unread message

Rajendra Prasad Gujja

unread,
Feb 11, 2016, 2:15:31 PM2/11/16
to play-framework

Hi All,

I am having a very hard time with Play in every step. Learning it in hard way :(

I am trying to write a functional test case to test the routes. I am using WithApplicaiton.

In my case, I need to store some information in Http.Context, I tried to create an Http.Context in my @Before method and trying to call Helpers.route method, however, it is creating a new Http.Context without copying the args that I set in @Before. That is causing lot of problems, I tried to use PowerMock but it is creating lot of problems related to class loaders.

It also not liking the custom HttpRequestHandler, its not even going there.

Any ideas on how can the context args copied to newly created context?

Thanks,
Raj.

Reply all
Reply to author
Forward
0 new messages