agent/consul/fsm: switch tests to use structs.TestIntention

This commit is contained in:
Mitchell Hashimoto 2018-03-04 19:14:19 -08:00
parent 3a00564411
commit 67b017c95c
No known key found for this signature in database
GPG Key ID: 744E147AA52F5B0A
1 changed files with 2 additions and 7 deletions

View File

@ -1161,14 +1161,9 @@ func TestFSM_Intention_CRUD(t *testing.T) {
ixn := structs.IntentionRequest{ ixn := structs.IntentionRequest{
Datacenter: "dc1", Datacenter: "dc1",
Op: structs.IntentionOpCreate, Op: structs.IntentionOpCreate,
Intention: &structs.Intention{ Intention: structs.TestIntention(t),
ID: generateUUID(),
SourceNS: "default",
SourceName: "web",
DestinationNS: "default",
DestinationName: "db",
},
} }
ixn.Intention.ID = generateUUID()
{ {
buf, err := structs.Encode(structs.IntentionRequestType, ixn) buf, err := structs.Encode(structs.IntentionRequestType, ixn)