On Thu, 14 Oct 2004 12:18:32 -0400, Kyle McAbee <[EMAIL PROTECTED]> wrote: > Dear JMeter Users, > > Thank you again, sebb. I made a scoping error in my test plan and then described the > problem incorrectly. In the original example test plan, I did not indent the If > Controller line far enough to indicate its actual position in the hierarchy. My > apologies!
OK. Glad it's now working. > > Compare the two test plans below. > > In this test plan, the If Controller never evaluates to True, and HTTP Request 2 is > not executed. The If Controller is a child element of HTTP Request 1. > Not a good idea ...! The Controller won't ever be executed, which is why it did not matter what you used. The __log() function is useful for checking what is happening. [Or enable JMeter logging, but that applies to a class hiearchy, not indididual test elements, and you have to restart the test.] > Simple Controller > HTTP Request 1 > If Controller (never evaluates to True) > HTTP Request 2 > HTTP Request 3 > > The user manual states in Section 4.2.2, "Logic Controllers", that "Logic > Controllers may have as child elements . . . other Logic Controllers." And I might > have noted that the Add menu for an HTTP Request does not include "Logic Controller"! > Indeed. > In this test plan, the If Controller can evaluate to True. The If Controller is a > child element of the Simple Controller. > > Simple Controller > HTTP Request 1 > If Controller (can evaluate to True) > HTTP Request 2 > HTTP Request 3 > > Might we hope that a future version of JMeter will not allow us to drag and drop an > element in an illegal position in the test plan hierarchy? Yes, I already checked in a fix for that. It's in the 2.0 nightly build. It may need some tweaking, but AFAIK it does prevent most illegal moves. > Sincerely yours, > > Kyle > > -----Original Message----- > From: sebb [mailto:[EMAIL PROTECTED] > Sent: Wednesday, October 13, 2004 8:04 PM > To: JMeter Users List > Subject: Re: Condition in If Controlleralways evaluates to False ? > > On Wed, 13 Oct 2004 19:55:01 -0400, Kyle McAbee <[EMAIL PROTECTED]> wrote: > > Dear JMeter Users, > > > > In JMeter 2.0.1, I cannot get the Condition field of the If Controller to evaluate > > as True, even by hard-coding the value. There was a previous message about this > > issue called "RE: Syntax for Condition in If Controller?" on June 17, 2004. That > > person succeeded with hard-coding true with no quotes in JMeter 2.0.1. > > > > I have tried these conditions, which appear to fail: > > > > true > > 'true' > > "true" > > True > > 'True' > > "True" > > TRUE > > 'TRUE' > > "TRUE" > > > > In a test plan with the following structure, JMeter executes HTTP requests 1 and > > 3. It does not execute HTTP request 2. > > > > Simple Controller > > HTTP Request 1 > > If Controller > > HTTP Request 2 > > HTTP Request 3 > > Works for me (admittedly using Java Test samplers instead of HTTP) > > > Does anyone have a suggestion about how to approach this? If I can get the If > > Controller to execute HTTP Request 2, then I will go on to try to write a real > > condition for it to evaluate. > > Have you checked the jmeter log file? > > > Sincerely yours, > > > > Kyle > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

