Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Goblin OGM
Goblin
Commits
e45c3295
Unverified
Commit
e45c3295
authored
Feb 01, 2020
by
Jeffrey Phillips Freeman
💥
Browse files
Test: Reactivated and fixed some skipped tests.
parent
32433508
Pipeline
#256
passed with stage
in 1 minute and 53 seconds
Changes
3
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
CHANGELOG.md
View file @
e45c3295
...
...
@@ -2,6 +2,8 @@
## v2.2.3
*
Fixed bug when mapping an edge's properties introduced as a regression in newer gremlinpython versions.
## v2.2.2
*
updated to use aiobremlin v3.3.4 in order to get the correct dependency tree.
...
...
goblin/mapper.py
View file @
e45c3295
...
...
@@ -5,6 +5,7 @@ import functools
import
logging
from
goblin
import
exception
from
gremlin_python.process.traversal
import
T
logger
=
logging
.
getLogger
(
__name__
)
...
...
@@ -126,8 +127,8 @@ def map_vertex_property_to_ogm(result, element, *, mapping=None):
def
map_edge_to_ogm
(
result
,
props
,
element
,
*
,
mapping
=
None
):
"""Map an edge returned by DB to OGM edge"""
props
.
pop
(
'
id
'
)
label
=
props
.
pop
(
'
label
'
)
props
.
pop
(
T
.
id
)
label
=
props
.
pop
(
T
.
label
)
for
db_name
,
value
in
props
.
items
():
name
,
data_type
=
mapping
.
db_properties
.
get
(
db_name
,
(
db_name
,
None
))
if
data_type
:
...
...
tests/test_session.py
View file @
e45c3295
...
...
@@ -112,7 +112,6 @@ class TestCreationApi:
assert
result
is
jon
await
app
.
close
()
@
pytest
.
mark
.
skip
(
reason
=
"Test not working on all backends"
)
@
pytest
.
mark
.
asyncio
async
def
test_get_edge
(
self
,
app
,
person_class
,
place_class
,
lives_in_class
):
...
...
@@ -187,7 +186,6 @@ class TestCreationApi:
assert
person
is
session1
.
current
[
rid
]
await
app
.
close
()
@
pytest
.
mark
.
skip
(
reason
=
"Test not working on all backends"
)
@
pytest
.
mark
.
asyncio
async
def
test_remove_edge
(
self
,
app
,
person_class
,
place_class
,
lives_in_class
):
...
...
@@ -208,7 +206,6 @@ class TestCreationApi:
assert
not
result
await
app
.
close
()
@
pytest
.
mark
.
skip
(
reason
=
"Test not working on all backends"
)
@
pytest
.
mark
.
asyncio
async
def
test_remove_edge_foreign_session
(
self
,
app
,
person_class
,
place_class
,
lives_in_class
):
...
...
@@ -249,7 +246,6 @@ class TestCreationApi:
assert
not
result
.
age
await
app
.
close
()
@
pytest
.
mark
.
skip
(
reason
=
"Test not working on all backends"
)
#@pytest.mark.skipif(pytest.config.getoption('provider') == 'dse', reason='DSE')
@
pytest
.
mark
.
asyncio
async
def
test_update_edge
(
self
,
app
,
person_class
,
knows
):
...
...
@@ -351,7 +347,6 @@ class TestTraversalApi:
assert
dave
.
__label__
==
'unregistered'
await
app
.
close
()
@
pytest
.
mark
.
skip
(
reason
=
"Test not working on all backends"
)
@
pytest
.
mark
.
asyncio
async
def
test_unregistered_edge_desialization
(
self
,
app
):
session
=
await
app
.
session
()
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment