Closed Bug 1554873 Opened 5 years ago Closed 5 years ago

Simplify devtools/client/inspector/fonts/fonts.js and remove eslint-disable complexity


(DevTools :: Inspector, task, P3)



(firefox70 fixed)

Firefox 70
Tracking Status
firefox70 --- fixed


(Reporter: pbro, Assigned: arunmohandm)


(Blocks 1 open bug)



(1 file)

This file contains a special eslint comment to temporarily disable the complexity eslint rule since it contains one or more functions that exceed the maximum complexity threshold. The code should be simplified, and the comment removed. Link to the code in question:

Component: General → Inspector: Fonts
Priority: -- → P3

Hey Patrick, I am having issues running the tests while I was refactoring the convertUnits function.

I got the following output when I ran ./mach test devtools/client/inspector/fonts/test/browser_fontinspector_editor-font-size-conversion.js.

UNKNOWN TEST: devtools/client/inspector/fonts/test/browser_fontinspector_editor-font-size-conversion.js
I was unable to find tests from the given argument(s).

You should specify a test directory, filename, test suite name, or
abbreviation. If no arguments are given, there must be local file
changes and corresponding IMPACTED_TESTS annotations in
files relevant to those files.

It's possible my little brain doesn't know about the type of test you are
trying to execute. If you suspect this, please request support by filing
a bug at

Do you see what I am missing?

Flags: needinfo?(pbrosset)

This is very odd. I checked on my side, and this is the correct file path and file name for this test.
So mach test should be able to find it.
Check for the obvious things first: did you remove or move that file by accident? Is the file still listed correctly in devtools/client/inspector/fonts/test/browser.ini? Can you try running mach mochitest instead?
Let me know if you still have issues. I'm in the process of re-building now, but I can try later locally if you want.

Flags: needinfo?(pbrosset)
Pushed by
Refactor convertUnits function to remove disabled complexity eslint rule. r=pbro
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 70
Assignee: nobody → arunmohandm
Component: Inspector: Fonts → Inspector
You need to log in before you can comment on or make changes to this bug.