Tried changing the code as suggested, and it does not break any
existing tests, but that does not mean it is correct ... ;-)

Try using the User Parameters Pre-Processor instead of UDV; that seems
to work without needing the fix.

S
On 11/05/07, Vladimir Sitnikov <[EMAIL PROTECTED]> wrote:
Hi,

I've created a test like:
Loop:  4 iterations
 HTTP Sampler 1
    User Defined Variable:  j=1
 While: ${__javaScript(${j}<4,)}
    HTTP Sampler 2
       User Defined Variable:  j=${__intSum(${j}, 1,)}
 HTTP Sampler 3

Here, WhileController emulates "for j in 1..3 loop". The thing is every even
time JMeter rejects entering into WhileController. I am afraid, I am
completely unfamiliar with JMeter code, however, it looks like, there is a
workaround that works fine for me (see a patch bellow).

Another point is when I substitute WhileController with "Loop(1000){
IfController(condition){ HTTP Sampler 2 } }" JMeter works fine for me. That
means there is no error in the test plan.

Please, confirm whether this code change is OK or not.

--- WhileController.java_original   2007-05-11 19:18:32.000000000 +0400
+++ WhileController.java            2007-05-11 19:18:32.000000000 +0400
@@ -110,11 +110,11 @@
               if (current != 0) { // in the middle of the loop
                       return super.next();
               }
+               reInitialize(); // Don't even start the loop
               // Must be start of loop
               if (!endOfLoop(false)) {
                       return super.next(); // OK to continue
               }
-               reInitialize(); // Don't even start the loop
               return null;
       }


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to