title: Does Groovy auto-box boolean to Object by default?
body: <p>Consider this Java class:</p>
  
  <pre><code>public class Demo {
  
      public void a(boolean a){
          System.out.println("boolean was called");
      }
  
      public void a(Object a){
          System.out.println("Object was called");
      }
  
  }
  </code></pre>
  
  <p>Groovy class:</p>
  
  <pre><code>class Groovy {
      static void main(String[] args) {
          def demo = new Demo()
          demo.a(true)
      }
  }
  </code></pre>
  
  <p>Output:</p>
  
  <pre><code>Object was called
  </code></pre>
  
  <p>Writing a test for it in Groovy and passing in a primitive <code>true</code> calls <code>a(Object)</code> instead.</p>
  
  <p>Is this intended behaviour and how can I call the other method? (I'm on version 2.4.6)</p>
  
  <p>FYI this causes problems with EasyMock (#<a href="https://github.com/easymock/easymock/issues/180#issue-175890293" rel="nofollow">175890293</a>)</p>