From e3d7d846038d667ee9ae3bfb198a655bb11a6836 Mon Sep 17 00:00:00 2001 From: georglauterbach <44545919+georglauterbach@users.noreply.github.com> Date: Sun, 13 Oct 2024 11:28:00 +0000 Subject: [PATCH] adjust test so that CNAME is excluded Signed-off-by: georglauterbach <44545919+georglauterbach@users.noreply.github.com> --- tests/lib/Http/Client/DnsPinMiddlewareTest.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/lib/Http/Client/DnsPinMiddlewareTest.php b/tests/lib/Http/Client/DnsPinMiddlewareTest.php index 9d71af15c5dc5..68635a3241452 100644 --- a/tests/lib/Http/Client/DnsPinMiddlewareTest.php +++ b/tests/lib/Http/Client/DnsPinMiddlewareTest.php @@ -537,10 +537,11 @@ static function (RequestInterface $request, array $options) { ['nextcloud' => ['allow_local_address' => false]] ); - $this->assertCount(4, $dnsQueries); + $this->assertCount(3, $dnsQueries); $this->assertContains('example.com' . DNS_SOA, $dnsQueries); $this->assertContains('subsubdomain.subdomain.example.com' . DNS_A, $dnsQueries); $this->assertContains('subsubdomain.subdomain.example.com' . DNS_AAAA, $dnsQueries); - $this->assertContains('subsubdomain.subdomain.example.com' . DNS_CNAME, $dnsQueries); + // CNAME should not be queried of A or AAAA succeeded already + $this->assertNotContains('subsubdomain.subdomain.example.com' . DNS_AAAA, $dnsQueries); } }