Bug 57825 - __Random function fails if min value is equal to max value (regression related to 54453)
Summary: __Random function fails if min value is equal to max value (regression relate...
Status: RESOLVED FIXED
Alias: None
Product: JMeter - Now in Github
Classification: Unclassified
Component: Main (show other bugs)
Version: 2.13
Hardware: All All
: P2 regression (vote)
Target Milestone: ---
Assignee: JMeter issues mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-04-16 19:15 UTC by Philippe Mouawad
Modified: 2015-04-16 19:29 UTC (History)
1 user (show)



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Philippe Mouawad 2015-04-16 19:15:25 UTC
Since 2.13, ${__Random(1,1,value)} fails with:
java.lang.IllegalArgumentException
	at org.apache.jmeter.util.ThreadLocalRandom.nextLong(ThreadLocalRandom.java:168)
	at org.apache.jmeter.functions.Random.execute(Random.java:65)
	at org.apache.jmeter.engine.util.CompoundVariable.execute(CompoundVariable.java:142)
	at org.apache.jmeter.engine.util.CompoundVariable.execute(CompoundVariable.java:118)
	at org.apache.jmeter.testelement.property.FunctionProperty.getStringValue(FunctionProperty.java:101)
	at org.apache.jmeter.testelement.AbstractTestElement.getPropertyAsString(AbstractTestElement.java:274)
	at org.apache.jmeter.testelement.AbstractTestElement.getName(AbstractTestElement.java:167)
	at org.apache.jmeter.threads.JMeterThread.process_sampler(JMeterThread.java:492)
	at org.apache.jmeter.threads.JMeterThread.run(JMeterThread.java:261)
	at java.lang.Thread.run(Thread.java:745)
Comment 1 Philippe Mouawad 2015-04-16 19:28:29 UTC
Date: Thu Apr 16 19:27:18 2015
New Revision: 1674139

URL: http://svn.apache.org/r1674139
Log:
Bug 57825 - __Random function fails if min value is equal to max value (regression related to 54453)
Bugzilla Id: 57825

Modified:
    jmeter/trunk/src/functions/org/apache/jmeter/functions/Random.java
    jmeter/trunk/xdocs/changes.xml
Comment 2 Philippe Mouawad 2015-04-16 19:29:31 UTC
Date: Thu Apr 16 19:29:08 2015
New Revision: 1674140

URL: http://svn.apache.org/r1674140
Log:
Bug 57825 - __Random function fails if min value is equal to max value (regression related to 54453)
Add Unit Test
Bugzilla Id: 57825

Modified:
    jmeter/trunk/test/src/org/apache/jmeter/functions/PackageTest.java
Comment 3 The ASF infrastructure team 2022-09-24 20:37:59 UTC
This issue has been migrated to GitHub: https://github.com/apache/jmeter/issues/3583