Commit 0053becd authored by Thomas Markwalder's avatar Thomas Markwalder
Browse files

[master] Corrected dhcp_ddns::WatchSocket unit test failure

Unit test was failing as a closed fd passed to select() does not fail
on all OSs.  Changed the test so it verifies that the fd in question
no longer evaluates to ready to ready.
parent 9bcad85c
......@@ -194,8 +194,8 @@ TEST(WatchSocketTest, badReadOnClear) {
/// @todo maybe clear should never throw, log only
ASSERT_THROW(watch->clearReady(), WatchSocketError);
// Verify the select_fd fails as socket is invalid/closed.
EXPECT_EQ(-1, selectCheck(select_fd));
// Verify the select_fd does not evalute to ready.
EXPECT_NE(1, selectCheck(select_fd));
// Verify that getSelectFd() returns INVALID.
ASSERT_EQ(WatchSocket::INVALID_SOCKET, watch->getSelectFd());
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment