summaryrefslogtreecommitdiffhomepage
path: root/dhcpv6/option_bootfileurl_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'dhcpv6/option_bootfileurl_test.go')
-rw-r--r--dhcpv6/option_bootfileurl_test.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/dhcpv6/option_bootfileurl_test.go b/dhcpv6/option_bootfileurl_test.go
index ac45ef5..b65d644 100644
--- a/dhcpv6/option_bootfileurl_test.go
+++ b/dhcpv6/option_bootfileurl_test.go
@@ -9,11 +9,11 @@ import (
func TestOptBootFileURL(t *testing.T) {
expected := "https://insomniac.slackware.it"
- opt, err := parseOptBootFileURL([]byte(expected))
- if err != nil {
+ var opt optBootFileURL
+ if err := opt.FromBytes([]byte(expected)); err != nil {
t.Fatal(err)
}
- if string(opt) != expected {
+ if opt.url != expected {
t.Fatalf("Invalid boot file URL. Expected %v, got %v", expected, opt)
}
require.Contains(t, opt.String(), "https://insomniac.slackware.it", "String() should contain the correct BootFileUrl output")