#include "chrome/browser/picture_in_picture/picture_in_picture_bounds_cache.h"
#include <memory>
#include "chrome/test/base/chrome_render_view_host_test_harness.h"
#include "content/public/browser/web_contents.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "ui/display/display.h"
namespace {
class PictureInPictureBoundsCacheTest : public ChromeRenderViewHostTestHarness { … };
}
TEST_F(PictureInPictureBoundsCacheTest, HasNoInitialGuess) { … }
TEST_F(PictureInPictureBoundsCacheTest,
RemembersMostRecentBoundsForEmptyInitialSize) { … }
TEST_F(PictureInPictureBoundsCacheTest,
RemembersMostRecentBoundsForNonEmptyInitialSize) { … }
TEST_F(PictureInPictureBoundsCacheTest, DisplayMismatchDoesNotProvideBounds) { … }
TEST_F(PictureInPictureBoundsCacheTest, SizeMismatchDoesNotProvideBounds) { … }
TEST_F(PictureInPictureBoundsCacheTest,
EmptyRequestSizeMatchesWithNonEmptyCacheSize) { … }
TEST_F(PictureInPictureBoundsCacheTest,
NonEmptyRequestSizeMismatchesWithEmptyCacheSize) { … }
TEST_F(PictureInPictureBoundsCacheTest,
DifferentOriginsMismatchAndOnlyOneIsCached) { … }
TEST_F(PictureInPictureBoundsCacheTest, NavigatingThereAndBackStillMatches) { … }
TEST_F(PictureInPictureBoundsCacheTest, SameOriginsDifferentPathsMatch) { … }