chromium/chrome/browser/ui/views/tabs/tab_container_unittest.cc

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

#include <memory>

#include "base/memory/raw_ref.h"
#include "base/ranges/algorithm.h"
#include "chrome/browser/ui/layout_constants.h"
#include "chrome/browser/ui/tabs/features.h"
#include "chrome/browser/ui/ui_features.h"
#include "chrome/browser/ui/views/frame/browser_root_view.h"
#include "chrome/browser/ui/views/tabs/fake_base_tab_strip_controller.h"
#include "chrome/browser/ui/views/tabs/fake_tab_slot_controller.h"
#include "chrome/browser/ui/views/tabs/tab_close_button.h"
#include "chrome/browser/ui/views/tabs/tab_container_impl.h"
#include "chrome/browser/ui/views/tabs/tab_drag_context.h"
#include "chrome/browser/ui/views/tabs/tab_group_header.h"
#include "chrome/browser/ui/views/tabs/tab_group_views.h"
#include "chrome/browser/ui/views/tabs/tab_strip_layout_helper.h"
#include "chrome/browser/ui/views/tabs/tab_strip_types.h"
#include "chrome/browser/ui/views/tabs/tab_style_views.h"
#include "chrome/test/views/chrome_views_test_base.h"
#include "ui/accessibility/ax_node_data.h"
#include "ui/base/dragdrop/drag_drop_types.h"
#include "ui/base/dragdrop/drop_target_event.h"
#include "ui/base/metadata/metadata_header_macros.h"
#include "ui/base/metadata/metadata_impl_macros.h"
#include "ui/gfx/animation/animation_test_api.h"
#include "ui/views/accessibility/view_accessibility.h"
#include "ui/views/view_utils.h"
#include "ui/views/widget/widget.h"

namespace {

// Walks up the views hierarchy until it finds a tab view. It returns the
// found tab view, or nullptr if none is found.
views::View* FindTabView(views::View* view) {}

class FakeTabDragContext : public TabDragContextBase {};

BEGIN_METADATA()

class FakeTabContainerController final : public TabContainerController {};
}  // namespace

class TabContainerTest : public ChromeViewsTestBase {};

TEST_F(TabContainerTest, ExitsClosingModeAtStandardWidth) {}

TEST_F(TabContainerTest, StaysInClosingModeBelowStandardWidth) {}

TEST_F(TabContainerTest, ClosingModeAffectsMinWidth) {}

// After removing a tab followed by removing a tab in a tabgroup
// Should bring the subsequent tab to its place as expected in
// tab closing mode.
TEST_F(TabContainerTest, RemoveTabInGroupWithTabClosingMode) {}

// Verifies child view order matches model order.
TEST_F(TabContainerTest, TabViewOrder) {}

// Verifies child view order matches slot order with group headers.
TEST_F(TabContainerTest, TabViewOrderWithGroups) {}

namespace {
ui::DropTargetEvent MakeEventForDragLocation(const gfx::Point& p) {}
}  // namespace

TEST_F(TabContainerTest, DropIndexForDragLocationIsCorrect) {}

TEST_F(TabContainerTest, AccessibilityData) {}

TEST_F(TabContainerTest, GetEventHandlerForOverlappingArea) {}

TEST_F(TabContainerTest, GetTooltipHandler) {}

TEST_F(TabContainerTest, GroupHeaderBasics) {}

TEST_F(TabContainerTest, GroupHeaderBetweenTabs) {}

TEST_F(TabContainerTest, GroupHeaderMovesRightWithTab) {}

TEST_F(TabContainerTest, GroupHeaderMovesLeftWithTab) {}

TEST_F(TabContainerTest, GroupHeaderDoesntMoveReorderingTabsInGroup) {}

TEST_F(TabContainerTest, GroupHeaderMovesOnRegrouping) {}

TEST_F(TabContainerTest, UngroupedTabMovesLeftOfHeader) {}

TEST_F(TabContainerTest, DeleteTabGroupViewsWhenEmpty) {}

TEST_F(TabContainerTest, GroupUnderlineBasics) {}

TEST_F(TabContainerTest, UnderlineBoundsTabVisibilityChange) {}

TEST_F(TabContainerTest, UnderlineBoundsCollapsedGroupHeaderVisibilityChange) {}

TEST_F(TabContainerTest, GroupHighlightBasics) {}

TEST_F(TabContainerTest, PreferredWidthDuringAnimation) {}

TEST_F(TabContainerTest, PreferredWidthNotAffectedByTransferTabTo) {}

TEST_F(TabContainerTest, PreferredWidthAddTabToViewModel) {}

TEST_F(TabContainerTest, TabDestroyedWhileOutOfContainerDoesNotActuallyReturn) {}

TEST_F(TabContainerTest, GetLeadingTrailingElementsForZOrdering) {}

TEST_F(TabContainerTest, TabGroupHeaderAccessibleProperties) {}