thanks for your reply. by any chance could you include some code snipplets. i am new to pylons and am having a hard time piecing together your response.
On Mar 4, 12:58 am, Ian Bicking <[EMAIL PROTECTED]> wrote: > webguy7890 wrote: > > i wasn't able to figure this out after reading the references on > > pylons doc. any response/code snippets/advice would be much > > appreciated. > > > 1) fixures: how do you validate your response with the info from the > > database? for example, after i do response = app.post(...), i want to > > check if the data is really there. or pre-populate the db so that i > > could test a delete. > > If your tests are setup right, you should be able to access your models > directly. So you can just import your models and look at them. > > > 2) error status: on some restful controller examples, the author > > utilizes status 404 to report that the item they are trying to edit/ > > update/delete doesn't exists. however, nosetests seem to throw an > > error b/c the 404 error causes a AppError. Is there anyway to > > suppress/catch the AppError, and then assert a 404 error/response came > > back? > > There's an automatic assertion in there; add status=404 to your call if > you expect some other status. > > Ian --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
