Opened 7 years ago

Closed 7 years ago

#15704 closed New feature (fixed)

Make cache tests more reusable

Reported by: Jonas H. 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: no UI/UX: no


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 Jonas H. 7 years ago.

Download all attachments as: .zip

Change History (5)

Changed 7 years ago by Jonas H.

comment:1 Changed 7 years ago by Jonas H.

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

comment:2 Changed 7 years ago by Luke Plant

Type: New feature

comment:3 Changed 7 years ago by Luke Plant

Severity: Normal

comment:4 Changed 7 years ago by Adrian Holovaty

Resolution: fixed
Status: newclosed

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