### Question:
GeoGit extends FileVectorDriver<GeoGitWorkspace> { @Override protected GeoGitWorkspace create(File file, Map<?, Object> opts, Schema schema) throws IOException { GeoGitWorkspace ws = open(file, opts); ws.create(schema); return ws; }  static GeoGitWorkspace open(GeoGitOpts opts); @Override String name(); @Override List<Key<?>> keys(); @Override Class<GeoGitWorkspace> type(); @Override GeoGitWorkspace open(File file, Map<?, Object> opts); @Override boolean supports(VectorDriver.Capability cap); static final Key<String> USER; static final Key<String> EMAIL; }### Answer:
@Test public void testCreate() throws Exception { Schema widgets = new SchemaBuilder("widgets").field("shape", Polygon.class) .field("name", String.class).field("cost", Double.class).schema(); GeoGitDataset data = ws.create(widgets); assertEquals(0, data.count(new VectorQuery())); GeomBuilder gb = new GeomBuilder(); Transaction tx = data.transaction(null); Cursor<Feature> c = data.cursor(new VectorQuery().append().transaction(tx)); Feature f = c.next(); f.put("shape", gb.point(0,0).toPoint().buffer(10)); f.put("name", "bomb"); f.put("cost", 1.99); c.write(); f = c.next(); f.put("shape", gb.points(0,0,1,1).toLineString().buffer(1)); f.put("name", "dynamite"); f.put("cost", 2.99); c.write(); f = c.next(); f.put("shape", gb.points(-5,5, 5,5, 2,-2, 3,-5, -3,-5, -2,-2, -5,5).ring().toPolygon()); f.put("name", "anvil"); f.put("cost", 3.99); c.write(); tx.commit(); data = ws.get("widgets"); assertEquals(3, data.count(new VectorQuery())); c = data.cursor(new VectorQuery().filter("name = 'bomb'")); assertTrue(c.hasNext()); assertEquals(1.99, c.next().get("cost")); }