Closed Bug 1738245 Opened 3 years ago Closed 3 years ago

Remove OS.File usage from various browser/ tests

Categories

(Firefox :: General, task, P3)

task

Tracking

()

RESOLVED FIXED
96 Branch
Tracking Status
firefox96 --- fixed

People

(Reporter: standard8, Assigned: raquelvargas, Mentored)

References

Details

(Whiteboard: [lang=js][good-next-bug])

Attachments

(1 file)

Using OS.File for file access is now obsolete and can be replaced by code using IOUtils. Working towards this, in this bug we want remove all OS.File usage from these files:

  • browser/base/content/test/static/browser_all_files_referenced.js
  • browser/components/downloads/test/unit/test_DownloadsCommon_getMimeInfo.js
  • browser/components/extensions/test/browser/browser_ext_tabs_saveAsPDF.js
  • browser/components/migration/tests/unit/test_Chrome_bookmarks.js
  • browser/components/migration/tests/unit/test_MigrationUtils_timedRetry.js

The code in question can be found here.

There is background information here about how to migrate from OS.File to IOUtils. If you have questions, please ask.

To run the tests after you've built, you can run ./mach test path/to/file. You should also check ESLint before commiting: ./mach eslint browser/.

I'm happy to mentor this. Note this bug will be auto-assigned when the first patch is attached, but feel free to comment that you're working on it.

Severity: -- → N/A
Priority: -- → P3

I'd love to give this a try but I'm running into a few errors during tests, can I submit my patch?

Yes, it is always fine to post patches which are work in progress to get feedback - just make it clear that's what you are doing.

Assignee: nobody → raquelvargas
Status: NEW → ASSIGNED
Pushed by mbanner@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/a045ce98e572
Remove OS.File usage from various browser/ tests. r=Standard8,robwu

Backed out changeset a045ce98e572 (Bug 1738245) for causing xpcshell failures on test_MigrationUtils_timedRetry.js.
Backout link
Push with failures
Failure Log

Flags: needinfo?(raquelvargas)
Flags: needinfo?(raquelvargas)
Pushed by mbanner@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/aa33b5ca2b96
Remove OS.File usage from various browser/ tests. r=Standard8,robwu
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 96 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: