On Thu, Aug 12, 2010 at 4:58 PM, Richard Harding <[email protected]> wrote: > On Thu, Aug 12, 2010 at 3:49 PM, waugust <[email protected]> wrote: >> This is most likely a very trivial question, but believe me I did my >> due diligence and googled but alas I can't find the answer. >> >> All I'm trying to do is write tests for my controllers but I fail to >> see how to set an AUTH_USER environ variable. >> >> I thought to just instantiate my User model and pass it in the headers >> attribute of self.app.post though i get "AssertionError: Environmental >> variable HTTP_AUTH_USER is not a string:" >> >> What am I missing here? How do I mimic a logged in user when testing >> my controllers?
The others have explained the Repoze configuration better than I can, but I'll just point out that AUTH_USER has to be a string because it was defined in the early 1990s before the rise of OO scripting languages, so if you want interoperability with other software, it has to be a string. -- Mike Orr <[email protected]> -- You received this message because you are subscribed to the Google Groups "pylons-discuss" 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/pylons-discuss?hl=en.
