blob: 453e4dba0e7eee110a256a1cad35b24f76db6370 [file] [log] [blame]
// Copyright 2018 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CHROME_CHROME_CLEANER_STRINGS_STRING_TEST_HELPERS_H_
#define CHROME_CHROME_CLEANER_STRINGS_STRING_TEST_HELPERS_H_
#include <string>
#include <vector>
namespace chrome_cleaner {
// Turns a string constant into a vector containing embedded nulls by
// converting every '0' to null.
std::vector<wchar_t> CreateVectorWithNulls(const std::wstring& str);
// Returns a wstring obtained from |v| by replacing null characters with "\\0".
std::wstring FormatVectorWithNulls(const std::vector<wchar_t>& v);
} // namespace chrome_cleaner
#endif // CHROME_CHROME_CLEANER_STRINGS_STRING_TEST_HELPERS_H_