Skip to content

Commit

Permalink
[tests] deal with the No Such Record lines in the output of dns-sd (
Browse files Browse the repository at this point in the history
#11223)

When resolving a hostname, `dns-sd` may output a line saying `No Such
Record` with an all-zero address which should be discarded.
  • Loading branch information
superwhd authored Feb 7, 2025
1 parent 3385437 commit fd2e06d
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/scripts/thread-cert/node.py
Original file line number Diff line number Diff line change
Expand Up @@ -4040,6 +4040,8 @@ def discover_mdns_service(self, instance, name, host_name, timeout=2):
for line in self.bash(f'cat {host_name_file}', encoding='raw_unicode_escape'):
elements = line.split()
fullname = f'{host_name}.local.'
if 'No Such Record' in line:
continue
if fullname not in elements:
continue
if 'Add' not in elements:
Expand Down

0 comments on commit fd2e06d

Please sign in to comment.