Closed Bug 793250 Opened 12 years ago Closed 12 years ago

Stop writing text files to ~/Desktop on Mac

Categories

(Toolkit :: Downloads API, defect)

x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla20

People

(Reporter: coop, Assigned: Mook)

References

()

Details

Attachments

(1 file)

I know this is an issue on at least Snow Leopard. Some test (philor can't recall which one at present) writes a whole bunch of small textfiles to the ~/Desktop dir (see URL). This is likely going to cause some skew of the performance numbers, since we can't rely on the Desktop background to be static for subsequent tests.

Can we please figure out which test is creating these files and put them somewhere else if they are required?

I could workaround this by deleting the contents of ~/Desktop dir on startup, but that might make things even more variable, i.e. once we've filled up the screen with text files, performance should level out again.

I might suggest ~/Documents as an alternative.
They're in ~/Desktop because that's our default download directory on OS X, I think because Mac users are supposed to be messy and like clutter. And hoodies, clutter and hoodies.

There are actually several other mochitests that do the same sort of thing, download some files winding up with uniqued filenames, but everybody else cleans up after themselves.
Since the content is reportedly "Test data 1" "Test data 2" "Test data 3" and http://mxr.mozilla.org/mozilla-central/source/toolkit/components/downloads/test/unit/test_download_samename.js#116 does test.txt with that content, I'd say that's who's not cleaning up after themselves.
Blocks: 593815
Component: Talos → Download Manager
Product: Testing → Toolkit
Version: unspecified → Trunk
The Desktop location issue is bug 311292
This should hopefully do the trick.  Note that I'm pretty sure this will completely fail to clean up if the test fails half way... But at least it's better.
Attachment #681842 - Flags: review?(wjohnston)
Attachment #681842 - Flags: review?(wjohnston) → review+
https://hg.mozilla.org/integration/mozilla-inbound/rev/ac29f2bce342
Assignee: nobody → mook.moz+mozbz
Flags: in-testsuite-
https://hg.mozilla.org/mozilla-central/rev/ac29f2bce342
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla20
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: