I need to create a few user accounts as testing fixtures during some unit 
tests. How can I do the following via the web2py api? 

- create a new user account using Auth
- log that new user in using Auth
- log that user out
- delete that user account (as part of test tear-down)

If I've missed this in the manual, I'd be happy just to know what pages to 
look at. So far my reading hasn't yielded anything.

To clarify, I want to do this from within a pytest test module/suite where 
I already have a web2py environment (access to current, db, etc.) but do 
not have a user logged in. (I know, by the way, that I could mock the 
users, but so many tests will use them that it will be *much* easier to 
work with functional fixtures.)

Thanks,

Ian

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to