### Question:
UiSettings { public boolean isCompassEnabled() { if (compassView != null) { return compassView.isEnabled(); } else { return false; } } UiSettings(@NonNull Projection projection, @NonNull FocalPointChangeListener listener,
             float pixelRatio, MapView mapView); void setCompassEnabled(boolean compassEnabled); boolean isCompassEnabled(); @UiThread void setCompassGravity(int gravity); void setCompassFadeFacingNorth(boolean compassFadeFacingNorth); void setCompassImage(@NonNull Drawable compass); boolean isCompassFadeWhenFacingNorth(); int getCompassGravity(); @UiThread void setCompassMargins(@Px int left, @Px int top, @Px int right, @Px int bottom); @Px int getCompassMarginLeft(); @Px int getCompassMarginTop(); @Px int getCompassMarginRight(); @Px int getCompassMarginBottom(); @Nullable Drawable getCompassImage(); void setLogoEnabled(boolean enabled); boolean isLogoEnabled(); void setLogoGravity(int gravity); int getLogoGravity(); void setLogoMargins(@Px int left, @Px int top, @Px int right, @Px int bottom); @Px int getLogoMarginLeft(); @Px int getLogoMarginTop(); @Px int getLogoMarginRight(); @Px int getLogoMarginBottom(); void setAttributionEnabled(boolean enabled); boolean isAttributionEnabled(); void setAttributionDialogManager(@NonNull AttributionDialogManager attributionDialogManager); @Nullable AttributionDialogManager getAttributionDialogManager(); void setAttributionGravity(int gravity); int getAttributionGravity(); void setAttributionMargins(@Px int left, @Px int top, @Px int right, @Px int bottom); void setAttributionTintColor(@ColorInt int tintColor); @Px int getAttributionMarginLeft(); @Px int getAttributionMarginTop(); @Px int getAttributionMarginRight(); @Px int getAttributionMarginBottom(); void setRotateGesturesEnabled(boolean rotateGesturesEnabled); boolean isRotateGesturesEnabled(); void setTiltGesturesEnabled(boolean tiltGesturesEnabled); boolean isTiltGesturesEnabled(); void setZoomGesturesEnabled(boolean zoomGesturesEnabled); boolean isZoomGesturesEnabled(); void setDoubleTapGesturesEnabled(boolean doubleTapGesturesEnabled); boolean isDoubleTapGesturesEnabled(); boolean isQuickZoomGesturesEnabled(); void setQuickZoomGesturesEnabled(boolean quickZoomGesturesEnabled); float getZoomRate(); void setZoomRate(@FloatRange(from = 0f) float zoomRate); boolean isDeselectMarkersOnTap(); void setDeselectMarkersOnTap(boolean deselectMarkersOnTap); void setScrollGesturesEnabled(boolean scrollGesturesEnabled); boolean isScrollGesturesEnabled(); void setHorizontalScrollGesturesEnabled(boolean horizontalScrollGesturesEnabled); boolean isHorizontalScrollGesturesEnabled(); boolean isScaleVelocityAnimationEnabled(); void setScaleVelocityAnimationEnabled(boolean scaleVelocityAnimationEnabled); boolean isRotateVelocityAnimationEnabled(); void setRotateVelocityAnimationEnabled(boolean rotateVelocityAnimationEnabled); boolean isFlingVelocityAnimationEnabled(); void setFlingVelocityAnimationEnabled(boolean flingVelocityAnimationEnabled); void setAllVelocityAnimationsEnabled(boolean allVelocityAnimationsEnabled); @Deprecated boolean isIncreaseRotateThresholdWhenScaling(); @Deprecated void setIncreaseRotateThresholdWhenScaling(boolean increaseRotateThresholdWhenScaling); boolean isDisableRotateWhenScaling(); void setDisableRotateWhenScaling(boolean disableRotateWhenScaling); boolean isIncreaseScaleThresholdWhenRotating(); void setIncreaseScaleThresholdWhenRotating(boolean increaseScaleThresholdWhenRotating); void setAllGesturesEnabled(boolean enabled); boolean areAllGesturesEnabled(); void setFocalPoint(@Nullable PointF focalPoint); @Nullable PointF getFocalPoint(); float getHeight(); float getWidth(); void invalidate();  }### Answer:
@Test public void testGetCompassEnabled() { when(compassView.isEnabled()).thenReturn(true); assertEquals("Compass should be enabled", true, uiSettings.isCompassEnabled()); }