Return-Path: X-Original-To: apmail-commons-commits-archive@minotaur.apache.org Delivered-To: apmail-commons-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 72A98DCB8 for ; Sat, 4 Aug 2012 19:40:48 +0000 (UTC) Received: (qmail 36798 invoked by uid 500); 4 Aug 2012 19:40:48 -0000 Delivered-To: apmail-commons-commits-archive@commons.apache.org Received: (qmail 36740 invoked by uid 500); 4 Aug 2012 19:40:48 -0000 Mailing-List: contact commits-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@commons.apache.org Delivered-To: mailing list commits@commons.apache.org Received: (qmail 36733 invoked by uid 99); 4 Aug 2012 19:40:48 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 04 Aug 2012 19:40:48 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 04 Aug 2012 19:40:46 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id A2A4823888EA for ; Sat, 4 Aug 2012 19:40:03 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1369420 - /commons/proper/math/trunk/src/test/java/org/apache/commons/math3/distribution/RealDistributionAbstractTest.java Date: Sat, 04 Aug 2012 19:40:03 -0000 To: commits@commons.apache.org From: erans@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20120804194003.A2A4823888EA@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: erans Date: Sat Aug 4 19:40:03 2012 New Revision: 1369420 URL: http://svn.apache.org/viewvc?rev=1369420&view=rev Log: MATH-839 Indicating changes that cannot be performed before 4.0 (new method "probability(double,double)" can be only added to the interface in a major release). Modified: commons/proper/math/trunk/src/test/java/org/apache/commons/math3/distribution/RealDistributionAbstractTest.java Modified: commons/proper/math/trunk/src/test/java/org/apache/commons/math3/distribution/RealDistributionAbstractTest.java URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/test/java/org/apache/commons/math3/distribution/RealDistributionAbstractTest.java?rev=1369420&r1=1369419&r2=1369420&view=diff ============================================================================== --- commons/proper/math/trunk/src/test/java/org/apache/commons/math3/distribution/RealDistributionAbstractTest.java (original) +++ commons/proper/math/trunk/src/test/java/org/apache/commons/math3/distribution/RealDistributionAbstractTest.java Sat Aug 4 19:40:03 2012 @@ -153,6 +153,7 @@ public abstract class RealDistributionAb getTolerance()); } // verify cumulativeProbability(double, double) + // XXX In 4.0, "cumulativeProbability(double,double)" must be replaced with "probability" (MATH-839). for (int i = 0; i < cumulativeTestPoints.length; i++) { for (int j = 0; j < cumulativeTestPoints.length; j++) { if (cumulativeTestPoints[i] <= cumulativeTestPoints[j]) { @@ -233,6 +234,7 @@ public abstract class RealDistributionAb for (int i=1; i < cumulativeTestPoints.length; i++) { // check that cdf(x, x) = 0 + // XXX In 4.0, "cumulativeProbability(double,double)" must be replaced with "probability" (MATH-839). TestUtils.assertEquals(0d, distribution.cumulativeProbability (cumulativeTestPoints[i], cumulativeTestPoints[i]), tolerance); @@ -242,6 +244,7 @@ public abstract class RealDistributionAb double lower = FastMath.min(cumulativeTestPoints[i], cumulativeTestPoints[i -1]); double diff = distribution.cumulativeProbability(upper) - distribution.cumulativeProbability(lower); + // XXX In 4.0, "cumulativeProbability(double,double)" must be replaced with "probability" (MATH-839). double direct = distribution.cumulativeProbability(lower, upper); TestUtils.assertEquals("Inconsistent cumulative probabilities for (" + lower + "," + upper + ")", diff, direct, tolerance); @@ -254,6 +257,7 @@ public abstract class RealDistributionAb @Test public void testIllegalArguments() { try { + // XXX In 4.0, "cumulativeProbability(double,double)" must be replaced with "probability" (MATH-839). distribution.cumulativeProbability(1, 0); Assert.fail("Expecting MathIllegalArgumentException for bad cumulativeProbability interval"); } catch (MathIllegalArgumentException ex) {