use of org.pentaho.metaverse.api.model.BaseSynchronizedGraph in project pentaho-metaverse by pentaho.
the class SynchronizedGraphFactoryTest method testWrapGraph.
@Test
public void testWrapGraph() throws Exception {
Graph g = new TinkerGraph();
BaseSynchronizedGraph wrapped = (BaseSynchronizedGraph) SynchronizedGraphFactory.wrapGraph(g);
assertNotNull(wrapped);
assertTrue(wrapped.getGraph() instanceof IdGraph);
assertTrue(wrapped.getGraph() instanceof KeyIndexableGraph);
}
use of org.pentaho.metaverse.api.model.BaseSynchronizedGraph in project pentaho-metaverse by pentaho.
the class SynchronizedGraphFactoryTest method testOpen_Map.
@Test
public void testOpen_Map() throws Exception {
Map<String, String> config = new HashMap<String, String>();
config.put("blueprints.graph", "com.tinkerpop.blueprints.impls.tg.TinkerGraph");
Graph g = SynchronizedGraphFactory.open(config);
assertTrue(g instanceof BaseSynchronizedGraph);
}
use of org.pentaho.metaverse.api.model.BaseSynchronizedGraph in project pentaho-metaverse by pentaho.
the class SynchronizedGraphFactoryTest method testOpen_Configuration.
@Test
public void testOpen_Configuration() throws Exception {
Configuration config = new PropertiesConfiguration();
config.addProperty("blueprints.graph", "com.tinkerpop.blueprints.impls.tg.TinkerGraph");
Graph g = SynchronizedGraphFactory.open(config);
assertTrue(g instanceof BaseSynchronizedGraph);
}
use of org.pentaho.metaverse.api.model.BaseSynchronizedGraph in project pentaho-metaverse by pentaho.
the class SynchronizedGraphFactoryTest method testOpen_File.
@Test
public void testOpen_File() throws Exception {
String config = "src/test/resources/graph.properties";
Graph g = SynchronizedGraphFactory.open(config);
assertTrue(g instanceof BaseSynchronizedGraph);
}
Aggregations