title: How to mock reactive repository which returns Observable
body: <p>So i have repository, which provides the Observable to the client. Is there a way i can mock this repository, so i don't need to send location from my emulator or using the real device to gain some Location?</p>
  
  <p>Here is how the interface looks like:</p>
  
  <pre><code>interface RxLocationRepository {
  
  @SuppressLint("MissingPermission")
  fun onLocationUpdate(): Observable&lt;Location&gt;
  
  fun stopLocationUpdates()
  }
  </code></pre>
  
  <p>In my client side i use this like this:</p>
  
  <pre><code>class LocationManager(
      val rxLocationRepository: RxLocationRepository){
  
  private fun appendGeoEvent(location: Location) {
      val locationGeoEvent = LocationGeoEvent(
              accuracy = location.accuracy.toDouble(),
              latitude = location.latitude,
              longitude = location.longitude,
              timestampGeoEvent = location.time
      )
      processGeoEvent(locationGeoEvent)
  }
  
  compositeDisposable.add(rxLocationRepository.onLocationUpdate()
              .subscribe(Consumer { location -&gt;
                  appendGeoEvent(location)
              }))
   ....
  </code></pre>
  
  <p>So i sending this obtained location to my appendGeoEvent method.</p>
  
  <p>I can use for example Mockito, but i don't know how to mock this repository so i can use the fake locations.
  Also, i want to use Kotlin.</p>