Skip to content
Permalink
Browse files

[oracle] Some updates to Oracle provider test suite

Now the Oracle provider passes the data provider edit stress/
conformance tests without issue!
  • Loading branch information
nyalldawson committed Apr 26, 2018
1 parent bbd335a commit c78bdaebcad5bfe02420c86e9620447e68288c64
Showing with 9 additions and 2 deletions.
  1. +9 −2 tests/src/python/test_provider_oracle.py
@@ -64,7 +64,7 @@ def execSQLCommand(self, sql, ignore_errors=False):
query.finish()

# disabled: WIP
def disabled_getSource(self):
def getSource(self):
# create temporary table for edit tests
self.execSQLCommand('DROP TABLE "QGIS"."EDIT_DATA"', ignore_errors=True)
self.execSQLCommand("""CREATE TABLE QGIS.EDIT_DATA ("pk" INTEGER GENERATED by default ON null as IDENTITY(START WITH 1 INCREMENT BY 1) PRIMARY KEY, "cnt" INTEGER, "name" VARCHAR2(100), "name2" VARCHAR2(100), "num_char" VARCHAR2(100), GEOM SDO_GEOMETRY)""")
@@ -80,7 +80,7 @@ def disabled_getSource(self):
return vl

# disabled: WIP
def disabled_getEditableLayer(self):
def getEditableLayer(self):
return self.getSource()

def enableCompiler(self):
@@ -147,6 +147,13 @@ def uncompiledFilters(self):
])
return filters

def testAddFeatureWrongGeomType(self):
"""
We override this test for Oracle provider, because Oracle DBs don't care
about geometry type constraints
"""
pass

# HERE GO THE PROVIDER SPECIFIC TESTS
def testDateTimeTypes(self):
vl = QgsVectorLayer('%s table="QGIS"."DATE_TIMES" sql=' %

0 comments on commit c78bdae

Please sign in to comment.
You can’t perform that action at this time.