clang-tidy: Fix exception specification mismatch
The following error was reported during clang-tidy enablement due to
the exception specification of the overriding function being more lax
than the base version. This fix ensures that the exception
specification matches the base class destructor in gtest::Test.
'''
./test/async/fdio.cpp:30:5:
error: exception specification of overriding function is more lax than base version
30 | ~FdioTest() override
/usr/local/include/gtest/gtest.h:247:11: note: overridden virtual function is here
247 | virtual ~Test();
'''
Tested: Verified build and unit testing.
Change-Id: I5c016fed60afddb8ceda6f8c0d5f97d660a015f7
Signed-off-by: Jayanth Othayoth <ojayanth@gmail.com>
diff --git a/test/async/fdio.cpp b/test/async/fdio.cpp
index 62f084d..799c5d3 100644
--- a/test/async/fdio.cpp
+++ b/test/async/fdio.cpp
@@ -27,7 +27,7 @@
fdioInstance = std::make_unique<sdbusplus::async::fdio>(*ctx, fd);
}
- ~FdioTest() override
+ ~FdioTest() noexcept override
{
if (fd != -1)
{