#ifdef UNSAFE_BUFFERS_BUILD
#pragma allow_unsafe_buffers
#endif
#include "storage/common/database/database_identifier.h"
#include <stddef.h>
#include <string>
#include "base/test/scoped_feature_list.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "url/gurl.h"
#include "url/origin.h"
#include "url/url_features.h"
namespace storage {
TEST(DatabaseIdentifierTest, CreateIdentifierFromOrigin) { … }
TEST(DatabaseIdentifierTest, CreateIdentifierAllHostChars) { … }
class DatabaseIdentifierParamTest : public testing::TestWithParam<bool> { … };
TEST_P(DatabaseIdentifierParamTest, ExtractOriginDataFromIdentifier) { … }
INSTANTIATE_TEST_SUITE_P(…);
static GURL GURLToAndFromOriginIdentifier(const GURL& origin_url) { … }
static url::Origin OriginToAndFromOriginIdentifier(const url::Origin& origin) { … }
static void TestValidOriginIdentifier(bool expected_result,
const std::string& id) { … }
TEST(DatabaseIdentifierTest, OriginIdentifiers) { … }
TEST(DatabaseIdentifierTest, IsValidOriginIdentifier) { … }
}