diff options
Diffstat (limited to 'dhcpv6/option_ntp_server_test.go')
-rw-r--r-- | dhcpv6/option_ntp_server_test.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/dhcpv6/option_ntp_server_test.go b/dhcpv6/option_ntp_server_test.go index 6cc5dd3..105a753 100644 --- a/dhcpv6/option_ntp_server_test.go +++ b/dhcpv6/option_ntp_server_test.go @@ -79,4 +79,10 @@ func TestParseOptNTPServer(t *testing.T) { optFQDN, ok := o.Suboptions[1].(*NTPSuboptionSrvFQDN) require.True(t, ok) assert.Equal(t, *fqdn, rfc1035label.Labels(*optFQDN)) + + var mo MessageOptions + assert.Nil(t, mo.NTPServers()) + mo.Add(o) + // MessageOptions.NTPServers only returns server address values. + assert.Equal(t, []net.IP{ip}, mo.NTPServers()) } |