1
0
mirror of https://github.com/CLIUtils/CLI11.git synced 2025-04-29 12:13:52 +00:00

fix tests on aarch64 (#266)

* fix tests on aarch64
This commit is contained in:
ryan4729 2019-04-18 06:00:11 -07:00 committed by Henry Schreiner
parent 76d2cde656
commit 734af661c6

View File

@ -1,5 +1,6 @@
#include "app_helper.hpp"
#include <climits>
#include <complex>
#include <cstdint>
#include <cstdio>
@ -553,8 +554,8 @@ TEST(Types, TypeName) {
}
TEST(Types, OverflowSmall) {
char x;
auto strmax = std::to_string(INT8_MAX + 1);
signed char x;
auto strmax = std::to_string(SCHAR_MAX + 1);
EXPECT_FALSE(CLI::detail::lexical_cast(strmax, x));
unsigned char y;
@ -641,7 +642,7 @@ TEST(Types, LexicalCastParsable) {
}
TEST(Types, LexicalCastEnum) {
enum t1 : char { v1 = 5, v3 = 7, v5 = -9 };
enum t1 : signed char { v1 = 5, v3 = 7, v5 = -9 };
t1 output;
EXPECT_TRUE(CLI::detail::lexical_cast("-9", output));