Open Bug 1427346 Opened 7 years ago Updated 3 years ago

The type of return value of tabs.move() is different from Google Chrome

Categories

(WebExtensions :: General, defect, P5)

defect

Tracking

(firefox59 affected)

Tracking Status
firefox59 --- affected

People

(Reporter: ashie, Unassigned)

Details

Attachments

(2 files)

Attached file test-firefox.js
Steps to reproduce: * Run the attached test case with "tabs" permission. For example, open a debug window for "Tree Style Tab" extension (which has the permission) then paste the code. Expected: tabs.move() is expected to return a signle tabs.Tab object when only one tab is moved. (Output the following debug message: testMoveSingleTabInOneWindow SUCCESS testMoveSingleTabInOneWindow SUCCESS) Rationale: * https://developer.mozilla.org/en-US/Add-ons/WebExtensions/API/tabs/move > A Promise that will be fulfilled with a tabs.Tab object or an array of tabs.Tab objects * Google Chrome returns a single tabs.Tab object in this case. Actual: tabs.move() returns an array which contains a tabs.Tabs object. (Output the following debug message: testMoveSingleTabInOneWindow FAIL testMoveSingleTabInOneWindow FAIL) It seems that it never return a single tabs.Tabs object. The behavior of Firefox is different from Google Chrome.
Attached file test-chrome.js
A test for Google Chrome.
Priority: -- → P5
Product: Toolkit → WebExtensions
Component: Untriaged → General
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: