Bug 1323185 - Fix test_close_not_selected_tab for correctly closing a background tab.
It should not be possible to close a background tab via the menu shortcut.
Instead another method should be used, best here is the close button.
MozReview-Commit-ID: 3cZmAyPsnj7
--- a/testing/firefox-ui/tests/puppeteer/test_tabbar.py
+++ b/testing/firefox-ui/tests/puppeteer/test_tabbar.py
@@ -68,17 +68,17 @@ class TestTabBar(PuppeteerMixin, Marione
self.assertEqual(len(tabbar.tabs), 1)
self.assertEqual(tabbar.tabs[0].handle, self.marionette.current_window_handle)
self.assertNotEqual(new_tab.handle, tabbar.tabs[0].handle)
def test_close_not_selected_tab(self):
tabbar = self.browser.tabbar
new_tab = tabbar.open_tab()
- tabbar.close_tab(tabbar.tabs[0])
+ tabbar.close_tab(tabbar.tabs[0], trigger="button")
self.assertEqual(len(tabbar.tabs), 1)
self.assertEqual(new_tab, tabbar.tabs[0])
def test_close_all_tabs_except_first(self):
tabbar = self.browser.tabbar
orig_tab = tabbar.tabs[0]