title: How to test method that makes call to Repository?
body: <p>I am new to writing Junit tests. I would like to know how I can test a method such as the below:</p>
  
  <pre><code>    @Transactional
      public List&lt;Dog&gt; getAllDogs() {
          Iterable&lt;Dog&gt; allDogs = dogRepository.findAll();
          return Lists.newArrayList(allDogs);
      }
  </code></pre>
  
  <p><strong>DogRepository Class</strong> (note findall() method is inherited)</p>
  
  <pre><code>public interface DogRepository extends CrudRepository&lt;Dog, Integer&gt; {
  
  
  }
  </code></pre>