#include "third_party/blink/renderer/core/layout/text_autosizer.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/blink/renderer/core/frame/local_frame.h"
#include "third_party/blink/renderer/core/frame/viewport_data.h"
#include "third_party/blink/renderer/core/frame/web_local_frame_impl.h"
#include "third_party/blink/renderer/core/layout/layout_object.h"
#include "third_party/blink/renderer/core/loader/empty_clients.h"
#include "third_party/blink/renderer/core/testing/core_unit_test_helper.h"
#include "third_party/blink/renderer/core/testing/sim/sim_request.h"
#include "third_party/blink/renderer/core/testing/sim/sim_test.h"
#include "third_party/blink/renderer/platform/testing/runtime_enabled_features_test_helpers.h"
#include "third_party/blink/renderer/platform/testing/unit_test_helpers.h"
#include "ui/gfx/geometry/rect.h"
namespace blink {
class TextAutosizerClient : public RenderingTestChromeClient { … };
class TextAutosizerTest : public RenderingTest,
public testing::WithParamInterface<bool>,
private ScopedTextSizeAdjustImprovementsForTest { … };
INSTANTIATE_TEST_SUITE_P(…);
TEST_P(TextAutosizerTest, SimpleParagraph) { … }
TEST_P(TextAutosizerTest, TextSizeAdjustDisablesAutosizing) { … }
TEST_P(TextAutosizerTest, ParagraphWithChangingTextSizeAdjustment) { … }
TEST_P(TextAutosizerTest, ZeroTextSizeAdjustment) { … }
TEST_P(TextAutosizerTest, NegativeTextSizeAdjustment) { … }
TEST_P(TextAutosizerTest, TextSizeAdjustmentPixelUnits) { … }
TEST_P(TextAutosizerTest, NestedTextSizeAdjust) { … }
TEST_P(TextAutosizerTest, PrefixedTextSizeAdjustIsAlias) { … }
TEST_P(TextAutosizerTest, AccessibilityFontScaleFactor) { … }
TEST_P(TextAutosizerTest, AccessibilityFontScaleFactorWithTextSizeAdjustNone) { … }
TEST_P(TextAutosizerTest, ChangingAccessibilityFontScaleFactor) { … }
TEST_P(TextAutosizerTest, TextSizeAdjustDoesNotDisableAccessibility) { … }
TEST_P(TextAutosizerTest, DISABLED_TextSizeAdjustWithoutNeedingAutosizing) { … }
TEST_P(TextAutosizerTest, DeviceScaleAdjustmentWithViewport) { … }
TEST_P(TextAutosizerTest, ChangingSuperClusterFirstText) { … }
TEST_P(TextAutosizerTest, ChangingSuperClusterSecondText) { … }
TEST_P(TextAutosizerTest, AddingSuperCluster) { … }
TEST_P(TextAutosizerTest, ChangingInheritedClusterTextInsideSuperCluster) { … }
TEST_P(TextAutosizerTest, AutosizeInnerContentOfRuby) { … }
TEST_P(TextAutosizerTest, ResizeAndGlyphOverflowChanged) { … }
TEST_P(TextAutosizerTest, narrowContentInsideNestedWideBlock) { … }
TEST_P(TextAutosizerTest, LayoutViewWidthProvider) { … }
TEST_P(TextAutosizerTest, MultiColumns) { … }
TEST_P(TextAutosizerTest, MultiColumns2) { … }
TEST_P(TextAutosizerTest, ScaledbyDSF) { … }
TEST_P(TextAutosizerTest, ClusterHasNotEnoughTextToAutosizeForZoomDSF) { … }
TEST_P(TextAutosizerTest, ClusterHasEnoughTextToAutosizeForZoomDSF) { … }
TEST_P(TextAutosizerTest, AfterPrint) { … }
TEST_P(TextAutosizerTest, FingerprintWidth) { … }
TEST_P(TextAutosizerTest, UsedDeviceScaleAdjustmentUseCounterWithViewport) { … }
TEST_P(TextAutosizerTest, UsedDeviceScaleAdjustmentUseCounterWithoutViewport) { … }
class TextAutosizerSimTest : public SimTest,
public testing::WithParamInterface<bool>,
private ScopedTextSizeAdjustImprovementsForTest { … };
INSTANTIATE_TEST_SUITE_P(…);
TEST_P(TextAutosizerSimTest, CrossSiteUseCounter) { … }
TEST_P(TextAutosizerSimTest, ViewportChangesUpdateAutosizing) { … }
}