@Test
  public void testPreservesOptions() {
    Fixture.fakePhase(PhaseId.READ_DATA);
    when(adapter.getFlavor()).thenReturn(NeedsPositionFlavor.CONTINUOUS);
    GeolocationOptions options =
        new GeolocationOptions().setFrequency(10).enableHighAccuracy().setMaximumAge(10);
    when(adapter.getOptions()).thenReturn(options);

    synchronizer.preserveValues(object);

    assertNotNull(
        RWT.getServiceStore()
            .getAttribute(
                synchronizer.getObjectId()
                    + "."
                    + GeolocationSynchronizer.PROP_ENABLE_HIGH_ACCURACY));
    assertNotNull(
        RWT.getServiceStore()
            .getAttribute(
                synchronizer.getObjectId() + "." + GeolocationSynchronizer.PROP_FREQUENCY));
    assertNotNull(
        RWT.getServiceStore()
            .getAttribute(
                synchronizer.getObjectId() + "." + GeolocationSynchronizer.PROP_MAXIMUM_AGE));
  }
  @Test
  public void testPreservesValues() {
    Fixture.fakePhase(PhaseId.READ_DATA);
    when(adapter.getFlavor()).thenReturn(NeedsPositionFlavor.CONTINUOUS);
    synchronizer.preserveValues(object);

    assertNotNull(
        RWT.getServiceStore()
            .getAttribute(
                synchronizer.getObjectId() + "." + GeolocationSynchronizer.PROP_NEEDS_POSITION));
  }