#include "extensions/browser/app_window/app_window_geometry_cache.h"
#include "base/memory/raw_ptr.h"
#include <stddef.h>
#include <memory>
#include <utility>
#include "base/files/file_path.h"
#include "base/strings/string_number_conversions.h"
#include "components/prefs/mock_pref_change_callback.h"
#include "content/public/test/test_browser_context.h"
#include "content/public/test/test_utils.h"
#include "extensions/browser/extension_prefs.h"
#include "extensions/browser/extensions_test.h"
#include "extensions/browser/unloaded_extension_reason.h"
#include "extensions/common/extension_builder.h"
#include "extensions/common/extension_id.h"
namespace extensions {
namespace {
const char kWindowId[] = …;
const char kWindowId2[] = …;
scoped_refptr<const Extension> CreateExtension(const ExtensionId& id) { … }
}
class AppWindowGeometryCacheTest : public ExtensionsTest { … };
void AppWindowGeometryCacheTest::SetUp() { … }
void AppWindowGeometryCacheTest::TearDown() { … }
void AppWindowGeometryCacheTest::AddGeometryAndLoadExtension(
const ExtensionId& extension_id,
const std::string& window_id,
const gfx::Rect& bounds,
const gfx::Rect& screen_bounds,
ui::WindowShowState state) { … }
void AppWindowGeometryCacheTest::WaitForSync() { … }
void AppWindowGeometryCacheTest::LoadExtension(
const ExtensionId& extension_id) { … }
void AppWindowGeometryCacheTest::UnloadExtension(
const ExtensionId& extension_id) { … }
ExtensionId AppWindowGeometryCacheTest::AddExtensionWithPrefs(
const std::string& name) { … }
TEST_F(AppWindowGeometryCacheTest, GetGeometryEmptyStore) { … }
TEST_F(AppWindowGeometryCacheTest, GetGeometryUnkownExtension) { … }
TEST_F(AppWindowGeometryCacheTest, GetGeometryUnkownWindow) { … }
TEST_F(AppWindowGeometryCacheTest, GetGeometryAndStateFromStore) { … }
TEST_F(AppWindowGeometryCacheTest, CorruptBounds) { … }
TEST_F(AppWindowGeometryCacheTest, CorruptScreenBounds) { … }
TEST_F(AppWindowGeometryCacheTest, CorruptState) { … }
TEST_F(AppWindowGeometryCacheTest, SaveGeometryAndStateToStore) { … }
TEST_F(AppWindowGeometryCacheTest, NoDuplicateWrites) { … }
TEST_F(AppWindowGeometryCacheTest, MaxWindows) { … }
}