Re: Unit test failing when testing post of a comment

2010-11-14 Thread Phil Gyford
Answering myself, in case this is useful to anyone in the future... I eventually discovered the problem lay in the method which checked submitted comments for spam (a method along these lines: http://sciyoshi.com/blog/2008/aug/27/using-akismet-djangos-new-comments-framework/ ). It expected the

Unit test failing when testing post of a comment

2010-11-11 Thread Phil Gyford
Hi, I have a unit test that tests that a comment can be posted on an entry in a Django blog. Posting a comment myself in the browser works fine, but the test always fails with this error: "TemplateSyntaxError: Caught VariableDoesNotExist while rendering: Failed lookup for key [request] in