Opened 3 years ago

Closed 3 years ago

Last modified 3 years ago

#20158 closed Bug (fixed)

Test models for pickled querysets have invalid code

Reported by: bmispelon Owned by: bmispelon
Component: Testing framework Version: master
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


The models located in tests/queryset_pickle/ use some defaults that can't actually be called.

This doesn't show when running the tests because no models are actually created so the problematic functions are never called.

The standalone_number function and the Numbers.get_static_number static method shouldn't actually take any parameter.

Change History (3)

comment:1 Changed 3 years ago by bmispelon

  • Has patch set
  • Needs documentation unset
  • Needs tests unset
  • Owner changed from nobody to bmispelon
  • Patch needs improvement unset
  • Status changed from new to assigned

PR here:

I fixed both function's signatures and added a setUp method on the testcase that creates a Happening instance.

comment:2 Changed 3 years ago by Baptiste Mispelon <bmispelon@…>

  • Resolution set to fixed
  • Status changed from assigned to closed

In a40746b1cbc912119f9f873614017953b17a4d7a:

Fix #20158: invalid code in queryset_pickle test models.

comment:3 Changed 3 years ago by Claude Paroz <claude@…>

In 24e710e65995b7f9edcd44efb81ae2681808e7ca:

Merge pull request #975 from bmispelon/ticket-20158

Fix #20158: invalid code in queryset_pickle test models.

Note: See TracTickets for help on using tickets.
Back to Top