Thanks for the help,
Relevant section of the traceback is as follows:
File
"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/unittest/loader.py",
line 91, in loadTestsFromName
module = __import__('.'.join(parts_copy))
File "/Users/benjamin/Project/app/dev/Project/project/schemas.py", line
171, in <module>
class TheSchema(colander.Schema):
File "/Users/benjamin/Project/app/dev/Project/project/schemas.py", line
176, in TheSchema
widget = deform.widget.SelectWidget(values=helper()),
File "/Users/benjamin/Project/app/dev/Project/project/schemas.py", line
168, in helper
# SQLA query is done here
It seems that the unittest loader is loading the schema class as one of its
tests, which then makes the helper call and fails.
Commenting out the TheSchema class allows the test to run as normal.
Thanks,
Ben
On 2 March 2012 19:05, Mike Orr <[email protected]> wrote:
> On Fri, Mar 2, 2012 at 3:16 AM, Benjamin Sims <[email protected]>
> wrote:
> > on the grounds that there is no bind for DBSession in helper() above. I
> > understand that there is no bind, but helper is not called explicitly nor
> > required by anything in the tests.
>
> Does the traceback say who called helper()? What happens if you
> comment out the helper function?
>
> --
> 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.
>
>
--
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.