#include "components/services/storage/dom_storage/session_storage_namespace_impl.h"
#include "base/barrier_closure.h"
#include "base/containers/contains.h"
#include "base/functional/bind.h"
#include "base/functional/callback_helpers.h"
#include "base/memory/ptr_util.h"
#include "base/run_loop.h"
#include "base/task/thread_pool.h"
#include "base/test/bind.h"
#include "base/test/gmock_callback_support.h"
#include "base/test/task_environment.h"
#include "base/uuid.h"
#include "components/services/storage/dom_storage/async_dom_storage_database.h"
#include "components/services/storage/dom_storage/dom_storage_database.h"
#include "components/services/storage/dom_storage/session_storage_data_map.h"
#include "components/services/storage/dom_storage/session_storage_metadata.h"
#include "components/services/storage/dom_storage/storage_area_test_util.h"
#include "mojo/public/cpp/bindings/remote.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/blink/public/common/storage_key/storage_key.h"
#include "url/gurl.h"
namespace storage {
namespace {
NamespaceEntry;
std::vector<uint8_t> StdStringToUint8Vector(const std::string& s) { … }
MATCHER(OKStatus, "Equality matcher for type OK leveldb::Status") { … }
class MockListener : public SessionStorageDataMap::Listener { … };
class SessionStorageNamespaceImplTest
: public testing::Test,
public SessionStorageNamespaceImpl::Delegate { … };
TEST_F(SessionStorageNamespaceImplTest, MetadataLoad) { … }
TEST_F(SessionStorageNamespaceImplTest, MetadataLoadWithMapOperations) { … }
TEST_F(SessionStorageNamespaceImplTest, CloneBeforeBind) { … }
TEST_F(SessionStorageNamespaceImplTest, CloneAfterBind) { … }
TEST_F(SessionStorageNamespaceImplTest, RemoveStorageKeyData) { … }
TEST_F(SessionStorageNamespaceImplTest, RemoveStorageKeyDataWithoutBinding) { … }
TEST_F(SessionStorageNamespaceImplTest, PurgeUnused) { … }
}
TEST_F(SessionStorageNamespaceImplTest, ReopenClonedAreaAfterPurge) { … }
}