[Cardinal] Add builders for Intents and remove extra constructors.
Starting with PointToPoint intent to see how it looks
Change-Id: I5366a05d657ceaad18c03b95cd71f5d1107200e2
diff --git a/core/api/src/test/java/org/onosproject/net/intent/PointToPointIntentTest.java b/core/api/src/test/java/org/onosproject/net/intent/PointToPointIntentTest.java
index fc18242..7171e7a 100644
--- a/core/api/src/test/java/org/onosproject/net/intent/PointToPointIntentTest.java
+++ b/core/api/src/test/java/org/onosproject/net/intent/PointToPointIntentTest.java
@@ -44,11 +44,23 @@
@Override
protected PointToPointIntent createOne() {
- return new PointToPointIntent(APPID, MATCH, NOP, P1, P2);
+ return PointToPointIntent.builder()
+ .appId(APPID)
+ .selector(MATCH)
+ .treatment(NOP)
+ .ingressPoint(P1)
+ .egressPoint(P2)
+ .build();
}
@Override
protected PointToPointIntent createAnother() {
- return new PointToPointIntent(APPID, MATCH, NOP, P2, P1);
+ return PointToPointIntent.builder()
+ .appId(APPID)
+ .selector(MATCH)
+ .treatment(NOP)
+ .ingressPoint(P2)
+ .egressPoint(P1)
+ .build();
}
}