#include "cc/tiles/picture_layer_tiling_set.h"
#include <map>
#include <vector>
#include "build/build_config.h"
#include "cc/test/fake_output_surface_client.h"
#include "cc/test/fake_picture_layer_tiling_client.h"
#include "cc/test/fake_raster_source.h"
#include "cc/trees/layer_tree_settings.h"
#include "components/viz/client/client_resource_provider.h"
#include "components/viz/test/fake_output_surface.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "ui/gfx/geometry/size_conversions.h"
namespace cc {
namespace {
class TestablePictureLayerTilingSet : public PictureLayerTilingSet { … };
std::unique_ptr<TestablePictureLayerTilingSet> CreateTilingSetWithSettings(
PictureLayerTilingClient* client,
const LayerTreeSettings& settings) { … }
std::unique_ptr<TestablePictureLayerTilingSet> CreateTilingSet(
PictureLayerTilingClient* client) { … }
TEST(PictureLayerTilingSetTest, TilingRange) { … }
class PictureLayerTilingSetTestWithResources : public testing::Test { … };
TEST_F(PictureLayerTilingSetTestWithResources, NoTilings) { … }
TEST_F(PictureLayerTilingSetTestWithResources, OneTiling_Smaller) { … }
TEST_F(PictureLayerTilingSetTestWithResources, OneTiling_Larger) { … }
TEST_F(PictureLayerTilingSetTestWithResources, TwoTilings_Smaller) { … }
TEST_F(PictureLayerTilingSetTestWithResources, TwoTilings_SmallerEqual) { … }
TEST_F(PictureLayerTilingSetTestWithResources, TwoTilings_LargerEqual) { … }
TEST_F(PictureLayerTilingSetTestWithResources, TwoTilings_Larger) { … }
#if BUILDFLAG(IS_LINUX) && defined(THREAD_SANITIZER)
#define MAYBE_ManyTilings_Equal …
#else
#define MAYBE_ManyTilings_Equal …
#endif
TEST_F(PictureLayerTilingSetTestWithResources, MAYBE_ManyTilings_Equal) { … }
#if BUILDFLAG(IS_LINUX) && defined(THREAD_SANITIZER)
#define MAYBE_ManyTilings_NotEqual …
#else
#define MAYBE_ManyTilings_NotEqual …
#endif
TEST_F(PictureLayerTilingSetTestWithResources, MAYBE_ManyTilings_NotEqual) { … }
TEST(PictureLayerTilingSetTest, TileSizeChange) { … }
TEST(PictureLayerTilingSetTest, ModifyPendingTilingSetTwiceInOneVsync) { … }
TEST(PictureLayerTilingSetTest, MaxContentScale) { … }
TEST(PictureLayerTilingSetTest, SkewportLimits) { … }
TEST(PictureLayerTilingSetTest, ComputeSkewportExtremeCases) { … }
TEST(PictureLayerTilingSetTest, ComputeSkewport) { … }
TEST(PictureLayerTilingSetTest, SkewportThroughUpdateTilePriorities) { … }
TEST(PictureLayerTilingTest, ViewportDistanceWithScale) { … }
TEST(PictureLayerTilingTest, InvalidateAfterComputeTilePriorityRects) { … }
TEST(PictureLayerTilingTest, InvalidateAfterUpdateRasterSourceForCommit) { … }
TEST(PictureLayerTilingSetTest, TilingTranslationChanges) { … }
TEST(PictureLayerTilingSetTest, LcdChanges) { … }
}
}