Uploaded image for project: 'Wicket'
  1. Wicket
  2. WICKET-3860

StoredResponsesMapTest Random.nextInt takes only positive integer arguments, not 0

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Trivial
    • Resolution: Fixed
    • 1.5-RC5.1
    • 1.5-RC6
    • wicket
    • None
    • all

    Description

      In the test StoredResponsesMapTest the line:
      String key2 = keys.get(rnd.nextInt(keys.size() - 1));
      has a problem since the integer argument to Random.nextInt can not be 0, but the keys
      List has size 1.

      Attachments

        Activity

          People

            mgrigorov Martin Tzvetanov Grigorov
            emberson Richard Emberson
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: