chromium/chrome/browser/ui/tabs/tab_menu_model_unittest.cc

// Copyright 2012 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "chrome/browser/ui/tabs/tab_menu_model.h"

#include "base/test/scoped_feature_list.h"
#include "chrome/browser/feed/web_feed_tab_helper.h"
#include "chrome/browser/optimization_guide/optimization_guide_keyed_service.h"
#include "chrome/browser/optimization_guide/optimization_guide_keyed_service_factory.h"
#include "chrome/browser/ui/browser_commands.h"
#include "chrome/browser/ui/tabs/existing_base_sub_menu_model.h"
#include "chrome/browser/ui/tabs/organization/tab_organization_utils.h"
#include "chrome/browser/ui/tabs/tab_menu_model_delegate.h"
#include "chrome/browser/ui/tabs/test_tab_strip_model_delegate.h"
#include "chrome/browser/ui/tabs/test_util.h"
#include "chrome/browser/ui/ui_features.h"
#include "chrome/test/base/browser_with_test_window_test.h"
#include "chrome/test/base/menu_model_test.h"
#include "components/commerce/core/commerce_feature_list.h"
#include "components/optimization_guide/core/model_execution/model_execution_features.h"
#include "components/optimization_guide/core/optimization_guide_features.h"
#include "content/public/test/web_contents_tester.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "ui/base/models/menu_model.h"
#include "ui/base/ui_base_features.h"

class TabMenuModelTest : public MenuModelTest,
                         public BrowserWithTestWindowTest {};

TEST_F(TabMenuModelTest, Basics) {}

TEST_F(TabMenuModelTest, OrganizeTabs) {}

TEST_F(TabMenuModelTest, CommerceProductSpecs) {}

TEST_F(TabMenuModelTest, CommerceProductSpecsIncognito) {}

TEST_F(TabMenuModelTest, CommerceProductSpecsInvalidScheme) {}

TEST_F(TabMenuModelTest, CommerceProductSpecsHttp) {}

TEST_F(TabMenuModelTest, CommerceProductSpecsFeatureCheck) {}

TEST_F(TabMenuModelTest, CommerceProductSpecsInsuffcientSelection) {}

TEST_F(TabMenuModelTest, MoveToNewWindow) {}

TEST_F(TabMenuModelTest, AddToExistingGroupSubmenu) {}

TEST_F(TabMenuModelTest, AddToExistingGroupSubmenu_DoesNotIncludeCurrentGroup) {}

// In some cases, groups may change after the menu is created. For example an
// extension may modify groups while the menu is open. If a group referenced in
// the menu goes away, ensure we handle this gracefully.
//
// Regression test for crbug.com/1197875
TEST_F(TabMenuModelTest, AddToExistingGroupAfterGroupDestroyed) {}

class TabMenuModelTestTabStripModelDelegate : public TestTabStripModelDelegate {};

TEST_F(TabMenuModelTest, TabbedWebApp) {}

TEST_F(TabMenuModelTest, TabbedWebAppHomeTab) {}