mirror of
https://github.com/boostorg/lexical_cast.git
synced 2026-07-21 13:23:34 +00:00
Add macOS testing. (#75)
Fixes https://github.com/boostorg/lexical_cast/issues/76 --------- Co-authored-by: Antony Polukhin <antoshkka@gmail.com>
This commit is contained in:
committed by
GitHub
parent
02e5821ab3
commit
92e55e842e
@@ -37,6 +37,9 @@ jobs:
|
||||
compiler: clang++-14
|
||||
cxxstd: "03,11,14,17,2a"
|
||||
os: ubuntu-22.04
|
||||
- toolset: clang
|
||||
cxxstd: "11,14,17,20"
|
||||
os: macos-13
|
||||
|
||||
runs-on: ${{matrix.os}}
|
||||
|
||||
|
||||
+2
-1
@@ -48,7 +48,8 @@ test-suite conversion
|
||||
|
||||
# Make sure that LexicalCast works the same way as some of the C++ Standard Libraries
|
||||
[ run float_types_test.cpp : : : <define>BOOST_LEXICAL_CAST_DETAIL_TEST_ON_OLD
|
||||
<toolset>msvc:<build>no # could have outdated behavior in some border cases
|
||||
<toolset>msvc:<build>no # could have outdated behavior in some border cases
|
||||
<target-os>darwin:<build>no # may have outdated behavior in some border cases
|
||||
: float_types_non_opt
|
||||
]
|
||||
|
||||
|
||||
@@ -40,7 +40,8 @@
|
||||
#define BOOST_LCAST_NO_WCHAR_T
|
||||
#endif
|
||||
|
||||
#if defined(BOOST_HAS_INT128) && !defined(BOOST_LEXICAL_CAST_TEST_NO_128_INTS)
|
||||
// There's no typeinfo for unsigned __int128 in Xcode_15.0.1
|
||||
#if defined(BOOST_HAS_INT128) && !defined(BOOST_LEXICAL_CAST_TEST_NO_128_INTS) && !defined(__APPLE__)
|
||||
# define BOOST_LCAST_TEST_128 1
|
||||
#endif
|
||||
|
||||
|
||||
@@ -523,21 +523,23 @@ void operators_overload_test()
|
||||
}
|
||||
|
||||
|
||||
#if !defined(BOOST_NO_CXX11_CHAR16_T) && !defined(BOOST_NO_CXX11_UNICODE_LITERALS)
|
||||
void test_char16_conversions()
|
||||
{
|
||||
// There's no std::ctype<char16_t> in Xcode_15.0.1
|
||||
#if !defined(BOOST_NO_CXX11_CHAR16_T) && !defined(BOOST_NO_CXX11_UNICODE_LITERALS) && !defined(__APPLE__)
|
||||
BOOST_TEST(u"100" == lexical_cast<std::u16string>(u"100"));
|
||||
BOOST_TEST(u"1" == lexical_cast<std::u16string>(u'1'));
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
#if !defined(BOOST_NO_CXX11_CHAR16_T) && !defined(BOOST_NO_CXX11_UNICODE_LITERALS)
|
||||
void test_char32_conversions()
|
||||
{
|
||||
// There's no std::ctype<char32_t> in Xcode_15.0.1
|
||||
#if !defined(BOOST_NO_CXX11_CHAR32_T) && !defined(BOOST_NO_CXX11_UNICODE_LITERALS) && !defined(__APPLE__)
|
||||
BOOST_TEST(U"100" == lexical_cast<std::u32string>(U"100"));
|
||||
BOOST_TEST(U"1" == lexical_cast<std::u32string>(U'1'));
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
void test_getting_pointer_to_function()
|
||||
{
|
||||
@@ -585,12 +587,8 @@ int main()
|
||||
|
||||
test_char_types_conversions();
|
||||
operators_overload_test();
|
||||
#if !defined(BOOST_NO_CXX11_CHAR16_T) && !defined(BOOST_NO_CXX11_UNICODE_LITERALS)
|
||||
test_char16_conversions();
|
||||
#endif
|
||||
#if !defined(BOOST_NO_CXX11_CHAR32_T) && !defined(BOOST_NO_CXX11_UNICODE_LITERALS)
|
||||
test_char32_conversions();
|
||||
#endif
|
||||
test_getting_pointer_to_function();
|
||||
|
||||
return boost::report_errors();
|
||||
|
||||
Reference in New Issue
Block a user