I would like to do ticket #11627
(http://code.djangoproject.com/ticket/11627). However, when I took a
closer look, I have encountered a few complications, that I would like
to solve before getting down to coding. Also, I would like to ask for
patience. I am not yet very much into Django codebase, but I would
like to learn as much as possible and be able to work later on my own.

Allowing to explicitly run TestSuite instead of TestCase is simple,
because there is loadTestsFromName which can be used instead of
current loadTestsFromTestCase. The problem is with feeding this
TestSuite with TestCases or other TestSuites. I have experimented a
little and it seems, that Suite may be initiated with list of TestCase
instances, each with name of test method. Current testing framework
does this on TestCases, instancing each multiple times with different
method names. For TestSuites we should provide similar mechanism, that
would allow to specify easily TestSuites and TestCases and then
framework would do all instancing.

What I was thinking, is to provide all Test classes (both cases and
suites) as class attributes in a modified TestSuite. When such a
TestSuite is run using django framework, it would feed with proper
instances, basing on those classes. This way end user would be able to
group his tests easily - just create a TestSuite and TestCases/Suites
it uses and all the magic would be done by us. What do you think about
it?

Another aspect is: when several TestCases are first created and then
passed to a TestSuite, should they be run twice, if user just calls
./manage.py test? Once as a standalone TestCase and then in a
TestSuite?

-- 
Filip Gruszczyński

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django developers" 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/django-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to