Opened 8 years ago

Closed 8 years ago

#10041 closed (fixed)

Form tests are set to upload files to '/'

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

Description

The tests in tests/regressiontests/forms/models.py include a FileModel that's currently configured with upload_to='/' . Because of the changes in [8244], this is no longer allowed unless MEDIA_ROOT is also set to '/' , which is highly unlikely to be the case. Currently, the test doesn't attempt to save the file, so this doesn't cause a failure, but with the work on model validation, the behavior present in this test will cause the file to be saved, which does introduce a failure into the test suite.

Attachments (1)

10041.diff (1.1 KB) - added by Marty Alchin 8 years ago.
Updated the test to use a temporary directory, like other tests currently do.

Download all attachments as: .zip

Change History (2)

Changed 8 years ago by Marty Alchin

Attachment: 10041.diff added

Updated the test to use a temporary directory, like other tests currently do.

comment:1 Changed 8 years ago by Jacob

Resolution: fixed
Status: newclosed

(In [9765]) Fixed #10041: use a tempdir for files in the forms test. Thanks, Marty Alchin.

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