Skip to content

Commit 6997f36

Browse files
authored
Merge pull request #171 from emiliom/coding_std
Updated odm2api module path calls in tests/test_odm2 modules to remove deprecated use of ODM2 module hierarchy
2 parents d6f3f56 + e4b93d9 commit 6997f36

File tree

5 files changed

+15
-14
lines changed

5 files changed

+15
-14
lines changed

Diff for: tests/test_SessionFactory.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
from __future__ import (absolute_import, division, print_function)
22

3-
from odm2api.ODM2.models import CVElevationDatum, setSchema
43
from odm2api.ODMconnection import SessionFactory
4+
from odm2api.models import CVElevationDatum, setSchema
55

66
import pytest
77

@@ -15,10 +15,10 @@
1515
['mysql"root@Localhost/odm2', 'mysql', 'mysql+pymysql://root@localhost/odm2'],
1616
['postgresql_marchantariats_none', 'postgresql',
1717
'postgresql+psycopg2://postgres:None@localhost/marchantariats',
18-
'marchantariats', 'postgres', None],
18+
'marchantariats', 'postgres', None],
1919
['postgresql_marchantariats_empty', 'postgresql',
2020
'postgresql+psycopg2://postgres@localhost/marchantariats',
21-
'marchantariats', 'postgres', None],
21+
'marchantariats', 'postgres', None],
2222
['sqlite_wof', 'sqlite', 'sqlite:///./tests/spatialite/wof2odm/ODM2.sqlite', None, None, None]
2323
]
2424

Diff for: tests/test_connection.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
from __future__ import (absolute_import, division, print_function)
22

3-
from odm2api.ODM2.models import CVElevationDatum
43
from odm2api.ODMconnection import dbconnection
4+
from odm2api.models import CVElevationDatum
55

66
import pytest
77

@@ -13,7 +13,7 @@
1313
dbs_readonly = [
1414
['mysql_odm2_odm', 'mysql', 'localhost', 'odm2', 'ODM', 'odm'],
1515
['mysql_odm2_root', 'mysql', 'localhost', 'odm2', 'root', None],
16-
['postgresql_marchantariats', 'postgresql', 'localhost', 'marchantariats', 'postgres', 'iforget'],
16+
['postgresql_marchantariats', 'postgresql', 'localhost', 'marchantariats', 'postgres', 'iforget'],
1717
['sqlite_wof', 'sqlite', './tests/spatialite/wof2odm/ODM2.sqlite', None, None, None]
1818
]
1919

Diff for: tests/test_odm2/test_createservice.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@
44
import uuid
55
from os.path import abspath, dirname, join
66

7-
from odm2api.ODM2 import models
8-
from odm2api.ODM2.services.createService import CreateODM2
7+
from odm2api import models
98
from odm2api.ODMconnection import dbconnection
9+
from odm2api.services.createService import CreateODM2
1010

1111
import pytest
1212
# run this test from the root directory using:

Diff for: tests/test_odm2/test_model.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
from __future__ import (absolute_import, division, print_function)
22

3-
from odm2api.ODM2.models import (CVElevationDatum, CVSamplingFeatureGeoType,
4-
CVSamplingFeatureType, SamplingFeatures)
3+
from odm2api.models import (CVElevationDatum, CVSamplingFeatureGeoType,
4+
CVSamplingFeatureType, SamplingFeatures)
55

66
import pytest
77

Diff for: tests/test_odm2/test_odm2.py

+6-5
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
from __future__ import (absolute_import, division, print_function)
22

3-
from odm2api.ODM2.models import Methods, Models, People, ProcessingLevels, RelatedModels, Variables
4-
from odm2api.ODM2.services.createService import CreateODM2
5-
from odm2api.ODM2.services.deleteService import DeleteODM2
6-
from odm2api.ODM2.services.readService import ReadODM2
7-
from odm2api.ODM2.services.updateService import UpdateODM2
83
from odm2api.ODMconnection import dbconnection
4+
from odm2api.models import (Methods, Models, People,
5+
ProcessingLevels, RelatedModels, Variables)
6+
from odm2api.services.createService import CreateODM2
7+
from odm2api.services.deleteService import DeleteODM2
8+
from odm2api.services.readService import ReadODM2
9+
from odm2api.services.updateService import UpdateODM2
910

1011
import pytest
1112

0 commit comments

Comments
 (0)