← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #202336]: weird error after calling unittest.main()

 

Question #202336 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/202336

    Status: Open => Answered

RaiMan proposed the following answer:
-- Can I assume that it is safe to continue to use unit tests this way?
Yes we can ;-)
ugly but safe.

As already mentioned above:

when using a structure like this without using unittest.main(), should
work without this error


import unittest

class TestA(TestCase):
...
...

suite = unittest.TestLoader().loadTestsFromTestCase(TestA) # see comment
unittest.TextTestRunner(verbosity=2).run(suite)

You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.