#23768: Rewrite template_tag.tests.TemplateTests as individual test cases
--------------------------------------+------------------------------------
     Reporter:  prestontimmons        |                    Owner:  nobody
         Type:  Cleanup/optimization  |                   Status:  new
    Component:  Template system       |                  Version:  master
     Severity:  Normal                |               Resolution:
     Keywords:                        |             Triage Stage:  Accepted
    Has patch:  1                     |      Needs documentation:  0
  Needs tests:  0                     |  Patch needs improvement:  1
Easy pickings:  0                     |                    UI/UX:  0
--------------------------------------+------------------------------------

Comment (by prestontimmons):

 I updated my pull request to include the remainder of the template tests.
 I'm going to do a final check through everything before unchecking patch
 needs improvement.

 For ease of auditing, I kept all the test methods named the same as
 before, i.e. include01, include02, etc. I think it would be good to add
 meaningful names in a separate patch.

 The new suite adds 640 tests, including the additional test for the setup
 function. The previous suite had 641 tests, two of which weren't really
 tests themselves: `include 05` and `include-cycle`. I verified this with
 this script:

 https://gist.github.com/prestontimmons/01ed288aaa2083afa2d4

 I didn't update the filter tests yet. I think these should also be done in
 a separate patch.

 I have a couple specific questions:

 1) There are two tests that seem to have wrong comments:

 * filter-syntax25
 * if-tag-shortcircuit02

 In both cases, the tests do the opposite of what the comment says. For
 `filter-syntax25` I believe the comment is wrong. For `if-tag-
 shortcircuit02`, I think the test is wrong.

 Does anyone else agree?

 2) I added a warnings filter for the url tag tests to the setup function.
 Is this done right? I'm not too familiar with how warnings work.

--
Ticket URL: <https://code.djangoproject.com/ticket/23768#comment:10>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/072.39362ab1a34b60ae3cad9bc3506abab3%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to