feat(mdns): Console test for add/remove delegated host APIs

This commit is contained in:
David Cermak
2024-07-22 11:42:18 +02:00
parent a91ead8ef5
commit ce7f326af0
3 changed files with 114 additions and 0 deletions

View File

@ -72,5 +72,15 @@ def test_remove_service(mdns_console, dig_app):
dig_app.check_record('_http._tcp.local', query_type='PTR', expected=False)
def test_delegate_host(mdns_console, dig_app):
mdns_console.send_input('mdns_delegate_host delegated 1.2.3.4')
dig_app.check_record('delegated.local', query_type='A', expected=True)
def test_undelegate_host(mdns_console, dig_app):
mdns_console.send_input('mdns_undelegate_host delegated')
dig_app.check_record('delegated.local', query_type='A', expected=False)
if __name__ == '__main__':
pytest.main(['-s', 'test_mdns.py'])