From e45e824a8fa168703fd7bfcd05bb733b22d81545 Mon Sep 17 00:00:00 2001 From: jtmelton Date: Wed, 4 Feb 2015 23:55:59 -0500 Subject: [PATCH] fixing type matches and type and detection point matches --- .../owasp/appsensor/core/DetectionPointTest.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/appsensor-core/src/test/java/org/owasp/appsensor/core/DetectionPointTest.java b/appsensor-core/src/test/java/org/owasp/appsensor/core/DetectionPointTest.java index 631b8e16..f4e3b4fc 100644 --- a/appsensor-core/src/test/java/org/owasp/appsensor/core/DetectionPointTest.java +++ b/appsensor-core/src/test/java/org/owasp/appsensor/core/DetectionPointTest.java @@ -8,7 +8,7 @@ public class DetectionPointTest { @Test(expected=IllegalArgumentException.class) public void testTypeMatchesNull() { DetectionPoint point1 = new DetectionPoint(); - point1.typeMatches(null); + point1.typeAndThresholdMatches(null); } @Test @@ -16,7 +16,7 @@ public void testTypeMatchesEmptyDetectionPoints() { DetectionPoint point1 = new DetectionPoint(); DetectionPoint point2 = new DetectionPoint(); - Assert.assertTrue(point1.typeMatches(point2)); + Assert.assertTrue(point1.typeAndThresholdMatches(point2)); } @Test @@ -26,7 +26,7 @@ public void testTypeMatchesFullMismatch() { DetectionPoint point2 = new DetectionPoint("b", "b1", new Threshold(5, new Interval(2, Interval.SECONDS))); - Assert.assertFalse(point1.typeMatches(point2)); + Assert.assertFalse(point1.typeAndThresholdMatches(point2)); } @Test @@ -36,7 +36,7 @@ public void testTypeMatchesCategoryMismatch() { DetectionPoint point2 = new DetectionPoint("a", "b1", new Threshold(5, new Interval(2, Interval.SECONDS))); - Assert.assertFalse(point1.typeMatches(point2)); + Assert.assertFalse(point1.typeAndThresholdMatches(point2)); } @Test @@ -46,7 +46,7 @@ public void testTypeMatchesLabelMismatch() { DetectionPoint point2 = new DetectionPoint("b", "a1", new Threshold(5, new Interval(2, Interval.SECONDS))); - Assert.assertFalse(point1.typeMatches(point2)); + Assert.assertFalse(point1.typeAndThresholdMatches(point2)); } @Test @@ -56,7 +56,7 @@ public void testTypeMatchesThresholdMismatch() { DetectionPoint point2 = new DetectionPoint("a", "a1", new Threshold(5, new Interval(2, Interval.SECONDS))); - Assert.assertTrue(point1.typeMatches(point2)); + Assert.assertFalse(point1.typeAndThresholdMatches(point2)); } @Test @@ -66,7 +66,7 @@ public void testTypeMatchesThresholdMatch() { DetectionPoint point2 = new DetectionPoint("a", "a1", new Threshold(5, new Interval(1, Interval.SECONDS))); - Assert.assertTrue(point1.typeMatches(point2)); + Assert.assertTrue(point1.typeAndThresholdMatches(point2)); }