On 8/18/06, citizenkahn <[EMAIL PROTECTED]> wrote:
>
> I have written some unit tests for my model using sqlite in-memory dbs.
> It all works with a single thread, but fails with multiple threads.
> Any ideas on how I can solve this problem? Thanks
may I ask why you need threaded access to the db in that test? does
you code actually does this?
> My Error: OperationalError: no such table: table2
>
> class ThreadTestCase(DBTestCase):
> def setUp(self):
> DBTestCase.setUp(self)
> .... # setup db
>
> def testthreads(self):
> t1 = controllers.processorThread('1')
> t2 = controllers.processorThread('1')
> t1.start()
> t2.start()
> .... # wait ERROR HAPPENS WHILE WAITING
> t1.join()
> t2.join()
> .... # look at contents
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"TurboGears" 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/turbogears
-~----------~----~----~----~------~----~------~--~---