From a13f2aeac88ccab79bb559b5b174f91c8c2007db Mon Sep 17 00:00:00 2001 From: Brad House Date: Fri, 14 Jun 2024 10:38:31 -0400 Subject: [PATCH] tests: set ndots:1 as default, don't honor system config as it may skew results --- test/ares-test.cc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/test/ares-test.cc b/test/ares-test.cc index aa28b0df..31e3a4a1 100644 --- a/test/ares-test.cc +++ b/test/ares-test.cc @@ -763,6 +763,11 @@ MockChannelOptsTest::MockChannelOptsTest(int count, optmask |= ARES_OPT_FLAGS; } + if (!(optmask & ARES_OPT_NDOTS)) { + opts.ndots = 1; + optmask |= ARES_OPT_NDOTS; + } + EXPECT_EQ(ARES_SUCCESS, ares_init_options(&channel_, &opts, optmask)); EXPECT_NE(nullptr, channel_);