BrushOptionsPreferences { public BrushColor getBrushColor() { int defaultColor = BrushColor.DARK.color(); int color = sharedPreferences.getInt(PREF_BRUSH_COLOR, defaultColor); return BrushColor.from(color); } protected  BrushOptionsPreferences(SharedPreferences sharedPreferences); static BrushOptionsPreferences newInstance(); void applyBrushSizePercentage(int percentage); int getBrushSizePercentage(); void applyBrushColor(BrushColor color); BrushColor getBrushColor(); int getBranchColor(); int getLeafColor();  }
@Test public void testThatGetBrushColorReturnsGetsValueFromSharedPreferences() { givenThatColorWasApplied(); assertThat(brushOptionsPreferences.getBrushColor()).isEqualTo(ANY_COLOR); }