package hx_url

import (
	"testing"
)

func TestHxUrl(t *testing.T) {
	swap := NewHxUrl("/wui/click/abc")
	if swap == nil {
		t.Fatalf("swap==nil")
	}
	if met := swap.Method(); met == nil {
		t.Fatalf("met==nil")
	}
	if patch := swap.Patch(); patch == nil {
		t.Fatalf("patch==nil")
	}
	if str := swap.String(); str != `hx-post="/wui/click/abc"` {
		t.Fatalf(`str(%v)!=(hx-post="/wui/click/abc")`, str)
	}
}
