#include "util/stdlib/string_number_conversion.h"
#include <sys/types.h>
#include <array>
#include <iterator>
#include <limits>
#include <type_traits>
#include "gtest/gtest.h"
#define STRINGIFY(a) …
#define STR(a) …
template <typename TValueType>
struct TestSpecification { … };
template <typename TIntType,
typename std::enable_if<std::is_integral<TIntType>::value &&
std::is_signed<TIntType>::value &&
(sizeof(TIntType) == 4)>::type* = nullptr>
static constexpr std::array<TestSpecification<TIntType>, 61> kTestDataFunc() { … }
template <typename TIntType,
typename std::enable_if<std::is_integral<TIntType>::value &&
!std::is_signed<TIntType>::value &&
(sizeof(TIntType) == 4)>::type* = nullptr>
static constexpr std::array<TestSpecification<TIntType>, 61> kTestDataFunc() { … }
template <typename TIntType,
typename std::enable_if<std::is_integral<TIntType>::value &&
std::is_signed<TIntType>::value &&
(sizeof(TIntType) == 8)>::type* = nullptr>
static constexpr std::array<TestSpecification<TIntType>, 24> kTestDataFunc() { … }
template <typename TIntType,
typename std::enable_if<std::is_integral<TIntType>::value &&
!std::is_signed<TIntType>::value &&
(sizeof(TIntType) == 8)>::type* = nullptr>
static constexpr std::array<TestSpecification<TIntType>, 25> kTestDataFunc() { … }
static constexpr char kEmbeddedNullInputRaw[] = …;
namespace crashpad {
namespace test {
namespace {
TEST(StringNumberConversion, StringToInt) { … }
TEST(StringNumberConversion, StringToUnsignedInt) { … }
TEST(StringNumberConversion, StringToLong) { … }
TEST(StringNumberConversion, StringToUnsignedLong) { … }
TEST(StringNumberConversion, StringToLongLong) { … }
TEST(StringNumberConversion, StringToUnsignedLongLong) { … }
}
}
}