Skip to content

Commit e08dd0a

Browse files
committed
refac: isolate disposable interface to new_tab test utility
1 parent 861d876 commit e08dd0a

2 files changed

Lines changed: 1 addition & 3 deletions

File tree

@types/gecko.d.mts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,6 @@ declare var MozElements: MozElements;
253253

254254
interface BrowserTab extends MozTabbrowserTab {
255255
_glide_commandline: GlideCommandLine | null;
256-
[Symbol.dispose](): void;
257-
[Symbol.asyncDispose](): Promise<void>;
258256
}
259257
// Source browser/components/tabbrowser/content/tab.js
260258
interface MozTabbrowserTab extends XULElement {

src/glide/browser/base/content/GlideTestUtils.sys.mts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ class GlideTestUtilsClass {
5050
* Behaves the same as `BrowserTestUtils.openNewForegroundTab()` but also defines
5151
* `[Symbol.dispose]()` so you can use it with `using`.
5252
*/
53-
async new_tab(uri?: string): Promise<BrowserTab> {
53+
async new_tab(uri?: string): Promise<BrowserTab & Disposable> {
5454
const tab = await g.BrowserTestUtils.openNewForegroundTab(g.gBrowser, uri);
5555
return Object.assign(tab, {
5656
[Symbol.dispose]() {

0 commit comments

Comments
 (0)