revsys / django-test-plus

Useful additions to Django's default TestCase

Home Page:https://django-test-plus.readthedocs.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

assertNumQueriesLessThan -> assertNumQueriesLessThanOrEqualTo

ftobia opened this issue · comments

The behavior of "assertNumQueriesLessThan" is actually less than or equal to.

executed <= self.num, "%d queries executed, expected less than %d" % (

I suggest one of:

  • change the name to match the behavior
  • change the behavior to match the name
  • include both functions and make the behavior correct for each

Oooh good catch thanks for reporting it!