Neep help for the logic to stimulate virtual users

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • rohitsharma1980
    New Member
    • Mar 2008
    • 2

    Neep help for the logic to stimulate virtual users

    hi ,
    i am new to Python. I am trying to make a script to stimulate virtual users.
    But i am getting some errors while doing so...can some one help me in this.

    the error is

    NameError: random

    at org.python.core .Py.NameError(P y.java)

    my functionis

    def getUserInfo(sel f):
    return random.choice(s elf._users)

    self._users is an array.

    i am importing following things:

    from java.lang import String
    from java.util import *
    from java.lang import *

    can anyone help me ...its urgent.

    or can anyone give me the logic for stimulating virtual users

    rohit
  • jlm699
    Contributor
    • Jul 2007
    • 314

    #2
    Did you import random?

    Comment

    • rohitsharma1980
      New Member
      • Mar 2008
      • 2

      #3
      yeah i import the random

      Comment

      Working...