Jorge Vargas schrieb:
> On Mon, Jan 5, 2009 at 9:25 AM, aubry-yves <[email protected]> wrote:
>>
>> Hello,
>> I write unit tests for an application TG2.
>> I followed these docs:
>> http://docs.turbogears.org/2.0/RoughDocs/AppTesting
>> http://wiki.pylonshq.com/display/pylonsdocs/Unit+Testing
>>
>> But I do not know how to test the pages with authenticated based on
>> repoze.who
>>
>> There is an example here, to assign a value to REMOTE_USER:
>> http://pythonpaste.org/webtest/#modifying-the-environment-simulating-authentication
>>
>> But it makes no difference.
> 
> Hi, I have been wanting to document this for some time, we had the
> same trouble on an application I'm working on.
> The short answer is that you need to call login on each request, one
> way of solving this is by using the following base webtest class.

I guess you mean "on each test" here, not request. For that reason, I 
would recommend putting the login-code into the setUp-call, but that's a 
matter of taste of course.

We maybe should grow some AuthenticatedTest-case-thingy to subclass from.

Diez

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to