Thank you for these essential details Ben! I'd be floundering big-time without your help.
I got the Oracle test running (without my changes) albeit not cleanly. There are a number of warnings and stack traces including some oracle SQL syntax errors such as an invalid reference to ROAD_ID and "table or view does not exist" (the oracle user can indeed create tables and has full dba privilege to create just about anything else too). Lots of warnings like this and similar... WARNING No mapping for com.vividsolutions.jts.geom.LinearRing Lots of warnings for errors closing connections. I see this during the test... SEVERE There's code using JDBC based datastore and not disposing them. This may lead to temporary loss of database connections. Please make sure all data access code calls DataStore.dispose() before freeing all references to it. (maybe related to failed tests not cleaning up properly?) When it's done I see: Tests run: 378, Failures: 3, Errors: 40, Skipped: 0 What's the difference between a "failure" and an "error"? More detail above this... Failed tests: OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testCreateSchema:167 expected:<3> but was:<206> OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureSourceRoad:927->JDBCTestSupport.assertFeatureTypesEqual:199->JDB CTestSupport.assertAttributesEqual:215 expected:<ID> but was:<ROAD_ID> OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetSchemaRoad:121 attributeCount expected:<3> but was:<9> Tests in error: OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeaturesWriterAdd:594 ╗ IO OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureReaderFilterTransaction:480 ╗ IO OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testUnLockFeatures:1132 ╗ ClassCast OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureWriterFilter:666 ╗ IO OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureWriterAppendTypeNameTransaction:646 ╗ IO OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureWriterRemove:561->JDBCDataStoreAPIOnlineTest.writer:1367 ╗ IO OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testLockFeatureInteraction:1161 ╗ ClassCast OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureWriterClose:537 ╗ IO OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureStoreSetFeatures:1098 ╗ ClassCast OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeaturesWriterModify:613->JDBCDataStoreAPIOnlineTest.writer:1367 ╗ IO OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureReaderMutability:356->JDBCDataStoreAPIOnlineTest.reader:1362 ╗ I O OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureStoreModifyFeatures1:1013 ╗ ClassCast OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureStoreModifyFeatures2:1032 ╗ ClassCast OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureStoreModifyFeatures3:1061 ╗ ClassCast OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureReaderFilterAutoCommit:451 ╗ IO OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureStoreRemoveAllFeatures:1080 ╗ ClassCast OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureStoreRemoveFeatures:1071 ╗ ClassCast OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureReader:171->JDBCDataStoreAPIOnlineTest.reader:1362 ╗ IO OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureReaderConcurrency:384->JDBCDataStoreAPIOnlineTest.reader:1362 ╗ IO OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureStoreAddFeatures:1088 ╗ ClassCast OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureWriterTypeNameTransaction:636 ╗ IO OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureWriterRemoveAll:578->JDBCDataStoreAPIOnlineTest.writer:1367 ╗ IO OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureReaderFilterPrePost:241 ╗ IO OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGeometryFactoryHintsCS:203 ╗ Runtime OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGeometryFactoryHintsGF:184 ╗ Runtime OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testGetFeatureLockingExpire:1214 ╗ ClassCast OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testLockFeatures:1122 ╗ ClassCast OracleDataStoreAPIOnlineTest>OnlineTestCase.run:123->JDBCDataStoreAPIOnlineTes t.testTransactionIsolation:711 ╗ IO OracleSpatialFiltersOnlineTest>OnlineTestCase.run:123->testSDODWithinOGCUnits: 63->validateOGCUnitUsage:97->JDBCSpatialFiltersOnlineTest.checkSingleResult:203 ╗ Runtime OracleSpatialFiltersOnlineTest>OnlineTestCase.run:123->testLooseBboxFilter:57- >JDBCSpatialFiltersOnlineTest.checkSingleResult:203 ╗ Runtime OracleSpatialFiltersOnlineTest>OnlineTestCase.run:123->JDBCSpatialFiltersOnlin eTest.testContainsFilter:157->JDBCSpatialFiltersOnlineTest.checkSingleResult:203 ╗ Runtime OracleSpatialFiltersOnlineTest>OnlineTestCase.run:123->JDBCSpatialFiltersOnlin eTest.testWithinFilter:175->JDBCSpatialFiltersOnlineTest.checkSingleResult:203 ╗ Runtime OracleSpatialFiltersOnlineTest>OnlineTestCase.run:123->JDBCSpatialFiltersOnlin eTest.testIntersectsFilter:122->JDBCSpatialFiltersOnlineTest.checkSingleResult:2 03 ╗ Runtime OracleSpatialFiltersOnlineTest>OnlineTestCase.run:123->JDBCSpatialFiltersOnlin eTest.testDisjointFilter:188->JDBCSpatialFiltersOnlineTest.checkSingleResult:203 ╗ Runtime OracleSpatialFiltersOnlineTest>OnlineTestCase.run:123->JDBCSpatialFiltersOnlin eTest.testTouchesFilter:144->JDBCSpatialFiltersOnlineTest.checkSingleResult:203 ╗ Runtime OracleSpatialFiltersOnlineTest>OnlineTestCase.run:123->JDBCSpatialFiltersOnlin eTest.testEqualsFilter:198->JDBCSpatialFiltersOnlineTest.checkSingleResult:203 ╗ Runtime OracleSpatialFiltersOnlineTest>OnlineTestCase.run:123->JDBCSpatialFiltersOnlin eTest.testBboxFilterDefault:100->JDBCSpatialFiltersOnlineTest.checkSingleResult: 202 ╗ Runtime OracleSpatialFiltersOnlineTest>OnlineTestCase.run:123->JDBCSpatialFiltersOnlin eTest.testIntersectsRingFilter:133->JDBCSpatialFiltersOnlineTest.checkSingleResu lt:203 ╗ Runtime OracleSpatialFiltersOnlineTest>OnlineTestCase.run:123->JDBCSpatialFiltersOnlin eTest.testCrossesFilter:111->JDBCSpatialFiltersOnlineTest.checkSingleResult:203 ╗ Runtime OracleSpatialFiltersOnlineTest>OnlineTestCase.run:123->JDBCSpatialFiltersOnlin eTest.testBboxFilter:92->JDBCSpatialFiltersOnlineTest.checkSingleResult:203 ╗ Ru ntime Being as new to the tool as I am and with limited time to invest, I'm not very prepared to dive into debugging those tests. Are they perhaps somehow obsolete or would you more suspect something about my environment? Thanks again - Walter -----Original Message----- From: Ben Caradoc-Davies [mailto:[email protected]] Sent: Wednesday, October 07, 2015 9:36 PM To: Walter Stovall; [email protected] Subject: Re: [Geotools-devel] I would like to make a bug fix and need help on the process On 08/10/15 06:11, Walter Stovall wrote: > Is there an appropriate way to run the test classes in the geotools eclipse > workspace? I do not currently have or support Oracle, but I have run GeoTools Oracle tests (gt-jdbc-oracle) in the past. I recommend first getting the Oracle tests running without your changes. In Eclipse to run all unit tests in a module, package, or class, right-click / Run As / JUnit Test. If you run oracle tests without configuring your oracle test fixture, the online test infrastructure will silently disable every test and give you a false pass. It is designed to disable tests when servers are not available. A working test should take minutes not seconds. The oracle fixture is configured with an oracle.properties file in a folder called ".geotools" in your home directory. On Linux this is ~/.geotools/oracle.properties and, although Windows will not let you make a folder starting with ".", the test infrastructure will make it for you when first run and then you can create oracle.properties inside it. oracle.properties should contain the following text (with your values substituted for UPPER_CASE_THINGS): dbtype = Oracle driver = oracle.jdbc.driver.OracleDriver url = jdbc:oracle:thin:@ORACLE_FULLY_QUALIFIED_HOST_NAME:1521:ORACLE_SID host = ORACLE_FULLY_QUALIFIED_HOST_NAME port = 1521 database = ORACLE_DATABASE user = ORACLE_USER passwd = ORACLE_PASSWORD password = ORACLE_PASSWORD There is a bit of duplication as some different keys are used in different places. Sorry about that. The oracle user will need permissions to create tables, views, and synonyms, perhaps more. I am not an Oracle DBA. See: https://www.seegrid.csiro.au/wiki/Infosrvices/JenkinsGeoserverMasterTechnicalNotes I recommend running tests in Maven first at the command line with in the jdbc-oracle folder: mvn -Ponline test It is mandatory to use -Ponline or Maven will skip every *OnlineTest. Once your tests are running in Maven, you should be able to run them in Eclipse as described above. Some temporal tests now fail in Eclipse after some recent work handling time zones. They pass in Maven. You may need to ignore these. Once you reach this point, you can start adding your SDO tests, but this is beyond my knowledge. Have a look in OracleTestSetup and the SDO*Test classes. > Should I create a pull request with my proposed change? I understand that > leads to an opportunity to discuss the fix. Maybe that's a better forum than > burdening this list? Process questions are always welcome here, as are technical discussions. Pull requests facilitate comments on individual lines and discussion of complete code that is ready to be merged. Fine detail can be easier in a PR. Feel free to use each forum as you see fit. Kind regards, -- Ben Caradoc-Davies <[email protected]> Director Transient Software Limited <http://transient.nz/> New Zealand ------------------------------------------------------------------------------ _______________________________________________ GeoTools-Devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/geotools-devel
