Opened 5 years ago

Closed 5 years ago

#15704 closed New feature (fixed)

Make cache tests more reusable

Reported by: jonash Owned by: nobody
Component: Core (Cache system) Version: master
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:


I'm using the cache framework test suite that ships with Django for my own caching backend.

This matches replaces the hard-coded backend paths (e.g. django.core.cache.backends.db) by class attributes, so using these tests for third-party backends is as easy as typing backend_name = ''.

Attachments (1)

cache-tests-backend-name.patch (8.7 KB) - added by jonash 5 years ago.

Download all attachments as: .zip

Change History (5)

Changed 5 years ago by jonash

comment:1 Changed 5 years ago by jonash

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset

Sorry. Second word should obviously be "patch". Again forgot to mention that this passes the Django test suite.

comment:2 Changed 5 years ago by lukeplant

  • Type set to New feature

comment:3 Changed 5 years ago by lukeplant

  • Severity set to Normal

comment:4 Changed 5 years ago by adrian

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

In [16008]:

Fixed #15704 -- Made cache tests more reusable by moving the backend path into a class attribute. Thanks for the patch, jonash

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