chromium/third_party/blink/common/unique_name/unique_name_helper_unittest.cc

// Copyright 2017 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "third_party/blink/public/common/unique_name/unique_name_helper.h"

#include <map>
#include <memory>
#include <optional>
#include <string_view>
#include <vector>

#include "base/auto_reset.h"
#include "base/memory/raw_ptr.h"
#include "base/ranges/algorithm.h"
#include "base/strings/utf_string_conversions.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/blink/public/common/page_state/page_state_serialization.h"

namespace blink {
namespace {

// Requested names longer than this (that are unique) should be hashed.
constexpr size_t kMaxSize =;

class TestFrameAdapter : public UniqueNameHelper::FrameAdapter {};

bool TestFrameAdapter::generate_legacy_name_ =;

// Test helper that verifies that legacy unique names in versions of PageState
// prior to 25 are correctly updated when deserialized.
void VerifyPageStateForTargetUpdate(const TestFrameAdapter& main_frame) {}

TEST(UniqueNameHelper, Basic) {}

TEST(UniqueNameHelper, Hashing) {}

// Verify that basic frame path generation always includes the full path from
// the root.
TEST(UniqueNameHelper, BasicGeneratedFramePath) {}

TEST(UniqueNameHelper, GeneratedFramePathHashing) {}

TEST(UniqueNameHelper, UpdateName) {}

}  // namespace
}  // namespace blink