Open Bug 1694367 Opened 5 years ago Updated 3 years ago

browser.tabs.print() has zero test coverage and is not async

Categories

(WebExtensions :: General, task, P3)

task

Tracking

(Not tracked)

People

(Reporter: robwu, Unassigned)

References

Details

The browser.tabs.print() was introduced along with browser.tabs.printPreview() in bug 1269300. It has two issues:

  1. There is zero test coverage.
  2. The method is not marked as async, so it's not possible to propagate errors back (e.g. if the tab is not visible).

In bug 1661241, a change to the implementation was proposed, but because of the lack of test coverage, the functionality may unexpectedly be broken.

dw-dev, do you want to add a unit test for this feature? Without unit tests this feature could break silently.

Flags: needinfo?(dw-dev)

Rob, I'm fairly sure that I had a discussion about testing of browser.tabs.print() when I implemented it and that no-one was to suggest how it could be tested. Of course, things have moved on and there may be a simple way to test it now. Unfortunately, I am tied up on other things at the moment and am unlikely to have time to progress this for some time.

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

Clear a needinfo that is pending on an inactive user.

Inactive users most likely will not respond; if the missing information is essential and cannot be collected another way, the bug maybe should be closed as INCOMPLETE.

For more information, please visit auto_nag documentation.

Flags: needinfo?(dw-dev)
You need to log in before you can comment on or make changes to this bug.