title: Is there anyway I can test in junit a method that tells if a character is repeating
body: <p>I need to test a method that checks if a character is repeating in JUnit and when I run the test, its sayinthing expected: false    .                                  </p>
  
  <pre><code>public boolean isRepeated(char ch) {
  
          ch = Character.toUpperCase(ch);
          for (char letter : guessLetter) {// guessLetter is a character ArrayList 
              if (letter == ch) {
                  return true;
  
              }
          }
          return false;
      }
  
  @Test
      void test() {
          game game=new game();
          boolean res=false;
          char c='A';
          res =game.isRepeated(c);
          String words = new String("AAAA");
          ArrayList&lt;Character&gt; guessLetter = new 
  ArrayList&lt;Character&gt;();
          for ( int i=0; i&lt;words.length(); i ++) {
              guessLetter.add(words.charAt(i));
  
          }
  
          assertEquals(res, guessLetter);
  
  
      }   
  </code></pre>