[
http://jira.jboss.com/jira/browse/JBAS-4291?page=comments#action_12358316 ]
Dimitris Andreadis commented on JBAS-4291:
------------------------------------------
Good catch, correct fix, but the comment is wrong :) To convert to msecs you'd have to
divide by 1000 not 100.
The division (percentage / 100) is needed to make it a true percentage for the
calculation, since the passed percentage is 15%, so it has to be 0.15 x expected, to give
the maximum diviation.
PeriodTestCase - wrong computation of maxDeviation
--------------------------------------------------
Key: JBAS-4291
URL:
http://jira.jboss.com/jira/browse/JBAS-4291
Project: JBoss Application Server
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: Test Suite
Affects Versions: JBossAS-5.0.0.Beta1, JBossAS-4.0.5.CR1, JBossAS-4.2.0.CR1
Reporter: Vivek Lakshmanan
Assigned To: Vivek Lakshmanan
Priority: Minor
Fix For: JBossAS-4.0.5.SP1 , JBossAS-4.2.0.GA, JBossAS-5.0.0.Beta2
Dominik Pospisil reports the following:
The calculation for maximum deviation
org.jboss.test.jbossmx.compliance.timer.PeriodTestCase, line 195
is incorrect and can lead to misleading failures on some testcases.
long maxDeviation = expected / percentage;
should be corrected to:
long maxDeviation = expected * percentage / 100;
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira