From 6e1010776f9353573d747ee8c180b9b27e528fc7 Mon Sep 17 00:00:00 2001 From: Hiroshi Yokoi Date: Thu, 30 Apr 2015 16:06:17 +0900 Subject: policy: use table.ProcessMessage() --- policy/policy_test.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/policy/policy_test.go b/policy/policy_test.go index 1f27fd4c..ca006ddb 100644 --- a/policy/policy_test.go +++ b/policy/policy_test.go @@ -650,8 +650,7 @@ func TestAsPathLengthConditionEvaluate(t *testing.T) { withdrawnRoutes := []bgp.WithdrawnRoute{} updateMsg := bgp.NewBGPUpdateMessage(withdrawnRoutes, pathAttributes, nlri) table.UpdatePathAttrs4ByteAs(updateMsg.Body.(*bgp.BGPUpdate)) - msg := table.NewProcessMessage(updateMsg, peer) - path := msg.ToPathList()[0] + path := table.ProcessMessage(updateMsg, peer)[0] // create match condition asPathLength := config.AsPathLength{ @@ -701,8 +700,7 @@ func TestAsPathLengthConditionWithOtherCondition(t *testing.T) { withdrawnRoutes := []bgp.WithdrawnRoute{} updateMsg := bgp.NewBGPUpdateMessage(withdrawnRoutes, pathAttributes, nlri) table.UpdatePathAttrs4ByteAs(updateMsg.Body.(*bgp.BGPUpdate)) - msg := table.NewProcessMessage(updateMsg, peer) - path := msg.ToPathList()[0] + path := table.ProcessMessage(updateMsg, peer)[0] // create policy ps := config.PrefixSet{ -- cgit v1.2.3