Mechanize requests run in the same thread as the currently executed test. The current zope.gloablrequest request is cleared after publishing when an IPubSuccess event is fired. This breaks getRequest for the current test-case.
With these changes the current zope.gloablrequest request is preserved after opening a page.
When using LIB_REQUESTS no changes are required since those requests run in another thread.
Mechanize requests run in the same thread as the currently executed test. The current zope.gloablrequest request is cleared after publishing when an IPubSuccess event is fired. This breaks getRequest for the current test-case.
With these changes the current zope.gloablrequest request is preserved after opening a page.
When using
LIB_REQUESTS
no changes are required since those requests run in another thread.