### Question:
GeoGigDataStoreFactory implements DataStoreFactorySpi { public @Override GeoGigDataStore createNewDataStore(Map<String, Serializable> params) throws IOException { String defaultNamespace = (String) DEFAULT_NAMESPACE.lookUp(params); URI repositoryRoot = resolveURI((String) REPOSITORY.lookUp(params)); RepositoryResolver initializer = RepositoryFinder.INSTANCE.lookup(repositoryRoot); if (initializer.repoExists(repositoryRoot)) { throw new IOException("Repository already exists " + repositoryRoot); } Geogig geogig; try { geogig = Geogig.create(repositoryRoot); } catch (RepositoryConnectionException | RuntimeException e) { throw new IOException(e); } GeoGigDataStore store = new GeoGigDataStore(geogig.getRepository()); if (defaultNamespace != null) { store.setNamespaceURI(defaultNamespace); } return store; }  @Override String getDisplayName(); @Override String getDescription(); @Override Param[] getParametersInfo(); @Override boolean canProcess(Map<String, Serializable> params); @Override boolean isAvailable(); @Override Map<Key, ?> getImplementationHints(); @Override GeoGigDataStore createDataStore(Map<String, Serializable> params); @Override GeoGigDataStore createNewDataStore(Map<String, Serializable> params); static final String DISPLAY_NAME; static final Param REPOSITORY; static final Param BRANCH; static final Param HEAD; static final Param DEFAULT_NAMESPACE; static final Param AUTO_INDEXING; }### Answer:
@Test public void testCreateNewDataStore() throws IOException { Map<String, Serializable> params; params = ImmutableMap.of(REPOSITORY.key, repoURI.resolve("newdatastore")); GeoGigDataStore store = factory.createNewDataStore(params); assertNotNull(store); store.dispose(); }