Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
caosdb-pylib
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
caosdb
Software
caosdb-pylib
Commits
a5f78b1b
Verified
Commit
a5f78b1b
authored
4 years ago
by
Timm Fitschen
Browse files
Options
Downloads
Patches
Plain Diff
REVIEW: fix tests
parent
402a1db1
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
unittests/test_add_property.py
+5
-3
5 additions, 3 deletions
unittests/test_add_property.py
with
5 additions
and
3 deletions
unittests/test_add_property.py
+
5
−
3
View file @
a5f78b1b
...
@@ -199,14 +199,16 @@ def test_property_parameter_with_entity_and_datatype():
...
@@ -199,14 +199,16 @@ def test_property_parameter_with_entity_and_datatype():
assert
concrete_property
.
value
is
None
assert
concrete_property
.
value
is
None
assert
concrete_property
.
datatype
==
db
.
INTEGER
assert
concrete_property
.
datatype
==
db
.
INTEGER
concrete_property
.
datatype
=
None
concrete_property
.
datatype
=
db
.
DOUBLE
concrete_property
.
value
=
3.14
concrete_property
.
value
=
3.14
with
raises
(
ValueError
):
with
raises
(
ValueError
):
# cannot parse 3.14 to integer
# cannot parse 3.14 to integer
concrete_property
.
datatype
=
db
.
INTEGER
concrete_property
.
datatype
=
db
.
INTEGER
concrete_property
.
datatype
=
None
concrete_property
.
value
=
3.14
# nothing should've changed after the ValueError
assert
concrete_property
.
datatype
==
db
.
DOUBLE
assert
concrete_property
.
value
==
3.14
def
test_kw_name_and_value
():
def
test_kw_name_and_value
():
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment