diff --git a/protocols/bgp/packet/path_attributes_test.go b/protocols/bgp/packet/path_attributes_test.go
index 3bd225984559e952a1a151c56834d15876a264ab..486f19d0d051476c58f54cd8edb6c5da62e75ff4 100644
--- a/protocols/bgp/packet/path_attributes_test.go
+++ b/protocols/bgp/packet/path_attributes_test.go
@@ -1442,7 +1442,7 @@ func TestSerializeCommunities(t *testing.T) {
 		{
 			name: "2 communities",
 			input: &PathAttribute{
-				TypeCode: LargeCommunitiesAttr,
+				TypeCode: CommunitiesAttr,
 				Value: []uint32{
 					131080, 16778241,
 				},