#ifdef UNSAFE_BUFFERS_BUILD
#pragma allow_unsafe_buffers
#endif
#include "components/url_formatter/url_fixer.h"
#include <stddef.h>
#include <stdlib.h>
#include <string>
#include "base/base_paths.h"
#include "base/files/file_path.h"
#include "base/files/file_util.h"
#include "base/files/scoped_temp_dir.h"
#include "base/strings/string_util.h"
#include "base/strings/utf_string_conversions.h"
#include "build/build_config.h"
#include "net/base/filename_util.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "url/gurl.h"
#include "url/third_party/mozilla/url_parse.h"
struct SegmentCase { … };
static const SegmentCase segment_cases[] = …;
URLFixerTest;
TEST(URLFixerTest, SegmentURL) { … }
static bool MakeTempFile(const base::FilePath& dir,
const base::FilePath& file_name,
base::FilePath* full_path) { … }
static bool IsMatchingFileURL(const std::string& url,
const base::FilePath& full_file_path) { … }
struct FixupCase { … } fixup_cases[] = …;
TEST(URLFixerTest, FixupURL) { … }
TEST(URLFixerTest, FixupFile) { … }
TEST(URLFixerTest, FixupRelativeFile) { … }