01: /*
02: * GeoTools - OpenSource mapping toolkit
03: * http://geotools.org
04: * (C) 2002-2006, GeoTools Project Managment Committee (PMC)
05: *
06: * This library is free software; you can redistribute it and/or
07: * modify it under the terms of the GNU Lesser General Public
08: * License as published by the Free Software Foundation;
09: * version 2.1 of the License.
10: *
11: * This library is distributed in the hope that it will be useful,
12: * but WITHOUT ANY WARRANTY; without even the implied warranty of
13: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14: * Lesser General Public License for more details.
15: */
16: package org.geotools.data.postgis;
17:
18: import java.io.IOException;
19:
20: import org.geotools.data.DataStore;
21: import org.geotools.feature.IllegalAttributeException;
22:
23: public class TransparentUnversionedOnlineTest extends
24: PostgisDataStoreAPIOnlineTest {
25:
26: public TransparentUnversionedOnlineTest(String test) {
27: super (test);
28: }
29:
30: protected void setupDbTables() throws Exception {
31: super .setupDbTables();
32: // make sure versioned metadata is not in the way
33: SqlTestUtils.dropTable(pool,
34: VersionedPostgisDataStore.TBL_TABLESCHANGED, false);
35: SqlTestUtils.dropTable(pool,
36: VersionedPostgisDataStore.TBL_VERSIONEDTABLES, false);
37: SqlTestUtils.dropTable(pool,
38: VersionedPostgisDataStore.TBL_CHANGESETS, true);
39: }
40:
41: public String getFixtureFile() {
42: return "versioned.properties";
43: }
44:
45: protected DataStore newDataStore() throws IOException {
46: VersionedPostgisDataStore ds = new VersionedPostgisDataStore(
47: pool, f.schema, getName(),
48: PostgisDataStore.OPTIMIZE_SQL);
49: ds.setWKBEnabled(true);
50: return ds;
51: }
52:
53: /**
54: * Return true if the datastore is capable of computing the road bounds given a query
55: * @return
56: */
57: protected boolean isEnvelopeComputingEnabled() {
58: return true;
59: }
60:
61: public void testOidFidMapper() throws IOException,
62: IllegalAttributeException {
63: // we have to override this one since versioned does not support oid mapper
64: }
65: }
|