mirror of
https://github.com/microsoft/GSL.git
synced 2025-04-02 09:18:33 -04:00
check on which platforms the first test fails
This commit is contained in:
parent
e31f8d76e5
commit
d88c5c01a5
@ -222,11 +222,11 @@ TEST(span_test, from_pointer_length_constructor)
|
|||||||
|
|
||||||
TEST(span_test, from_pointer_pointer_construction)
|
TEST(span_test, from_pointer_pointer_construction)
|
||||||
{
|
{
|
||||||
// const auto terminateHandler = std::set_terminate([] {
|
const auto terminateHandler = std::set_terminate([] {
|
||||||
// std::cerr << "Expected Death. from_pointer_pointer_construction";
|
std::cerr << "Expected Death. from_pointer_pointer_construction";
|
||||||
// std::abort();
|
std::abort();
|
||||||
// });
|
});
|
||||||
// const auto expected = GetExpectedDeathString(terminateHandler);
|
const auto expected = GetExpectedDeathString(terminateHandler);
|
||||||
|
|
||||||
int arr[4] = {1, 2, 3, 4};
|
int arr[4] = {1, 2, 3, 4};
|
||||||
|
|
||||||
@ -258,10 +258,10 @@ TEST(span_test, from_pointer_pointer_construction)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// this will fail the std::distance() precondition, which asserts on MSVC debug builds
|
// this will fail the std::distance() precondition, which asserts on MSVC debug builds
|
||||||
//{
|
{
|
||||||
// auto workaround_macro = [&]() { span<int> s{&arr[1], &arr[0]}; };
|
auto workaround_macro = [&]() { span<int> s{&arr[1], &arr[0]}; };
|
||||||
// EXPECT_DEATH(workaround_macro(), expected);
|
EXPECT_DEATH(workaround_macro(), expected);
|
||||||
//}
|
}
|
||||||
|
|
||||||
// this will fail the std::distance() precondition, which asserts on MSVC debug builds
|
// this will fail the std::distance() precondition, which asserts on MSVC debug builds
|
||||||
//{
|
//{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user