From 243fbe8d9331c61ac2b29e80b623c80b8226fe6c Mon Sep 17 00:00:00 2001 From: Christopher Dykes Date: Thu, 25 Aug 2016 14:53:29 -0700 Subject: [PATCH] Suppress an abort in FileUtilTest under MSVC Summary: Because MSVC is right, this shouldn't be happening, but we test weird things. Reviewed By: yfeldblum Differential Revision: D3773486 fbshipit-source-id: 50f28bf0ac8ff53f63231b4f6f9ce050b509b464 --- folly/test/FileUtilTest.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/folly/test/FileUtilTest.cpp b/folly/test/FileUtilTest.cpp index 6a63b33c..6526efa2 100644 --- a/folly/test/FileUtilTest.cpp +++ b/folly/test/FileUtilTest.cpp @@ -335,7 +335,9 @@ TEST_F(ReadFileFd, InvalidFd) { File f(aFile.path().string()); f.close(); std::string contents; - EXPECT_FALSE(readFile(f.fd(), contents)); + msvcSuppressAbortOnInvalidParams([&] { + EXPECT_FALSE(readFile(f.fd(), contents)); + }); PLOG(INFO); } }} // namespaces -- 2.34.1