func TestExcludePrefixesValidation(t *testing.T) {
	g := gomega.NewGomegaWithT(t)
	request := buildRequest()
	request.Connection.Context = &connectioncontext.ConnectionContext{
		IpContext: &connectioncontext.IPContext{DstIpAddr: "10.32.0.1/32"},
	}
	_, err := doRequest(g, request)
	g.Expect(err.Error()).To(gomega.MatchRegexp("dstIP .* intersects excluded prefixes list"))
	request.Connection.Context = &connectioncontext.ConnectionContext{
		IpContext: &connectioncontext.IPContext{SrcIpAddr: "10.32.0.1/32"},
	}
	_, err = doRequest(g, request)
	g.Expect(err.Error()).To(gomega.MatchRegexp("srcIP .* intersects excluded prefixes list"))
}
TestExcludePrefixesValidation checks IP address validation
package tests
import (
	"context"
	"os"
	"path"
	"strings"
	"testing"
	"github.com/onsi/gomega"
	"github.com/networkservicemesh/networkservicemesh/controlplane/api/connection"
	"github.com/networkservicemesh/networkservicemesh/controlplane/api/connectioncontext"
	"github.com/networkservicemesh/networkservicemesh/controlplane/api/networkservice"
	"github.com/networkservicemesh/networkservicemesh/controlplane/pkg/common"
	"github.com/networkservicemesh/networkservicemesh/sdk/prefix_pool"
)
var (
	prefixes = []string{"172.16.1.0/24", "10.32.0.0/12", "10.96.0.0/12"}
)
func TestExcludePrefixesInjection(t *testing.T) {
	g := gomega.NewGomegaWithT(t)
	request := buildRequest()
	conn, err := doRequest(g, request)
	g.Expect(err).To(gomega.BeNil())
	connPrefixes := conn.GetContext().GetIpContext().GetExcludedPrefixes()
	g.Expect(connPrefixes).To(gomega.ConsistOf(prefixes))
}