Repositories { @NonNull public static <T> Repository<T> repository(@NonNull final T object) { return new SimpleRepository<>(object); } private  Repositories(); @NonNull static Repository<T> repository(@NonNull final T object); @NonNull static REventSource<T, T> repositoryWithInitialValue(@NonNull final T initialValue); @NonNull static MutableRepository<T> mutableRepository(@NonNull final T object);  }
@Test public void shouldCreateStaticRepository() { assertThat(repository(1), has(1)); }
@Test public void shouldNotGetUpdatesFromStaticRepository() { final Repository<Integer> repository = repository(INITIAL_INT_VALUE); updatable.addToObservable(repository); assertThat(updatable, wasNotUpdated()); }