title: Test a class that calls static wrapper methods
body: <p>I have a static wrapper class for the android <code>Log</code>. </p>
  
  <p>It looks like this (simplified):</p>
  
  <pre><code>// Source: https://github.com/ccrama/Slide/blob/master/app/src/main/java/me/ccrama/redditslide/util/LogUtil.java
  public class LogUtil {
      private static final int CALLING_METHOD_INDEX;    
  
      static {
          int i = 1;
          for (StackTraceElement ste : Thread.currentThread().getStackTrace()) {
              i++;
              if (ste.getClassName().equals(LogUtil.class.getName())) {
                  break;
              }
          }
          CALLING_METHOD_INDEX = i;
      }
  
      public static String getTag() {
          final StackTraceElement ste = Thread.currentThread().getStackTrace()[CALLING_METHOD_INDEX];
          return "(" + ste.getFileName() + ":" + ste.getLineNumber() + ")";
      }
  
      public static void v(String message) {
          Log.v(getTag(), message);
      }
  }
  </code></pre>
  
  <p>My problem: I'm <strong>testing another method that calls this</strong> <code>LogUtil.v()</code>'s method.</p>
  
  <p>Is there a way to test the other method with Mockito and not Powermock(ito) if possible? </p>
  
  <p>Currently it throws a <code>LogUtil.v not mocked</code> Exception.</p>
  
  <p>I read that if I have to use PowerMockito, I'm doing something wrong (=> not following TDD).</p>