diff options
author | Hiroshi Yokoi <yokoi.hiroshi@po.ntts.co.jp> | 2015-06-02 20:25:58 +0900 |
---|---|---|
committer | Hiroshi Yokoi <yokoi.hiroshi@po.ntts.co.jp> | 2015-06-02 21:09:04 +0900 |
commit | e985f476a182f1a66084b3ed4b1c2376f9cc5018 (patch) | |
tree | 91dfbaf8f5685bac44afad834cbf4c1d32b7c8c5 /policy | |
parent | 007c0df5092df0be2e03df457dcfcb89c92080d6 (diff) |
packet: return aspath length based on the segment type.
Diffstat (limited to 'policy')
-rw-r--r-- | policy/policy_test.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/policy/policy_test.go b/policy/policy_test.go index e3951584..2eced491 100644 --- a/policy/policy_test.go +++ b/policy/policy_test.go @@ -527,7 +527,7 @@ func TestPolicyRejectOnlyNeighborSet(t *testing.T) { } func TestPolicyDifferentRoutefamilyOfPathAndPolicy(t *testing.T) { - // creatae path ipv4 + // create path ipv4 peerIPv4 := &table.PeerInfo{AS: 65001, Address: net.ParseIP("10.0.0.1")} originIPv4 := bgp.NewPathAttributeOrigin(0) aspathParamIPv4 := []bgp.AsPathParamInterface{bgp.NewAsPathParam(2, []uint16{65001})} @@ -539,7 +539,7 @@ func TestPolicyDifferentRoutefamilyOfPathAndPolicy(t *testing.T) { withdrawnRoutesIPv4 := []bgp.WithdrawnRoute{} updateMsgIPv4 := bgp.NewBGPUpdateMessage(withdrawnRoutesIPv4, pathAttributesIPv4, nlriIPv4) pathIPv4 := table.ProcessMessage(updateMsgIPv4, peerIPv4)[0] - // creatae path ipv6 + // create path ipv6 peerIPv6 := &table.PeerInfo{AS: 65001, Address: net.ParseIP("2001::192:168:50:1")} originIPv6 := bgp.NewPathAttributeOrigin(0) aspathParamIPv6 := []bgp.AsPathParamInterface{bgp.NewAsPathParam(2, []uint16{65001})} @@ -651,7 +651,7 @@ func TestAsPathLengthConditionEvaluate(t *testing.T) { // create match condition asPathLength := config.AsPathLength{ Operator: "eq", - Value: 8, + Value: 5, } c := NewAsPathLengthCondition(asPathLength) |