@Test
public void removeLayerOnMapShouldReturnTrueWhenStyleIsReadyAndRemoveLayersAndSources() {

    float textSize = 20f;
    float boundaryWidth = 6f;
    int colorInt = Color.GREEN;
    String labelProperty = "district-name";
    FeatureCollection featureCollection = FeatureCollection.fromFeatures(new ArrayList<Feature>());
    BoundaryLayer.Builder builder = new BoundaryLayer.Builder(featureCollection)
            .setLabelProperty(labelProperty)
            .setLabelTextSize(textSize)
            .setLabelColorInt(colorInt)
            .setBoundaryColor(colorInt)
            .setBoundaryWidth(boundaryWidth);
    BoundaryLayer boundaryLayer = builder.build();
    assertNull(ReflectionHelpers.getField(boundaryLayer, "boundarySource"));
    MapboxMap mapboxMap = Mockito.mock(MapboxMap.class);
    Style style = Mockito.mock(Style.class);
    SymbolLayer boundaryLabelLayer = Mockito.mock(SymbolLayer.class);
    LineLayer boundaryLineLayer = Mockito.mock(LineLayer.class);
    GeoJsonSource boundarySource = new GeoJsonSource("some-id");
    GeoJsonSource boundaryLabelsSource = new GeoJsonSource("some-id-2");
    Mockito.doReturn(true)
            .when(style)
            .isFullyLoaded();
    Mockito.doReturn(style)
            .when(mapboxMap)
            .getStyle();
    ReflectionHelpers.setField(boundaryLayer, "boundaryLabelLayer", boundaryLabelLayer);
    ReflectionHelpers.setField(boundaryLayer, "boundaryLineLayer", boundaryLineLayer);
    ReflectionHelpers.setField(boundaryLayer, "boundarySource", boundarySource);
    ReflectionHelpers.setField(boundaryLayer, "boundaryLabelsSource", boundaryLabelsSource);
    assertTrue(boundaryLayer.removeLayerOnMap(mapboxMap));
    Mockito.verify(style, Mockito.times(1))
            .removeLayer(ArgumentMatchers.eq(boundaryLabelLayer));
    Mockito.verify(style, Mockito.times(1))
            .removeLayer(ArgumentMatchers.eq(boundaryLineLayer));
    Mockito.verify(style, Mockito.times(1))
            .removeSource(ArgumentMatchers.eq(boundarySource));
    Mockito.verify(style, Mockito.times(1))
            .removeSource(ArgumentMatchers.eq(boundaryLabelsSource));
}