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
31cb27e6
Commit
31cb27e6
authored
4 years ago
by
Alexander Kreft
Browse files
Options
Downloads
Patches
Plain Diff
Rename variables
parent
c24d57bb
No related branches found
No related tags found
1 merge request
!14
F delete container
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
unittests/test_container.py
+8
-14
8 additions, 14 deletions
unittests/test_container.py
with
8 additions
and
14 deletions
unittests/test_container.py
+
8
−
14
View file @
31cb27e6
...
@@ -80,35 +80,29 @@ def test_get_property_values():
...
@@ -80,35 +80,29 @@ def test_get_property_values():
def
test_container_dependencies_for_deletion
():
def
test_container_dependencies_for_deletion
():
not_included_rt
=
1000
rt
=
db
.
RecordType
(
"
Just a RecordType
"
)
rt
=
db
.
RecordType
(
"
Just a RecordType
"
)
rt
.
id
=
1001
rt
.
id
=
1001
rt_dep
=
db
.
RecordType
(
"
Just another RecordType
"
)
rt_dep
.
id
=
1002
rt_record_without_dependencies
=
db
.
RecordType
(
"
Records without dependencies
"
)
rt_record_without_dependencies
.
id
=
1003
rt_record_with_dependencies
=
db
.
RecordType
(
"
Records with dependencies
"
)
rt_record_with_dependencies
.
id
=
1004
rt_record_with_parent
=
db
.
RecordType
(
"
Records with parent
"
)
rt_record_with_parent
=
db
.
RecordType
(
"
Records with parent
"
)
rt_record_with_parent
.
id
=
1005
rt_record_with_parent
.
id
=
1005
property_which_is_not_a_record
=
db
.
Property
(
property_which_is_not_a_record
=
db
.
Property
(
"
Normal Property
"
,
datatype
=
db
.
DOUBLE
,
value
=
1006
)
"
Normal Property
"
,
datatype
=
db
.
DOUBLE
,
value
=
1006
)
property_which_is_not_a_record
.
id
=
1006
property_which_is_not_a_record
.
id
=
1006
record_without_dependencies
=
db
.
Record
().
add_parent
(
rt_record_without_dependencies
)
record_without_dependencies
=
db
.
Record
().
add_parent
(
not_included_rt
)
record_without_dependencies
.
id
=
2003
record_without_dependencies
.
id
=
2003
record_
dep
=
db
.
Record
().
add_parent
(
rt_dep
)
record_
referenced
=
db
.
Record
().
add_parent
(
not_included_rt
)
record_
dep
.
id
=
2002
record_
referenced
.
id
=
2002
record_with_dependencies
=
db
.
Record
().
add_parent
(
rt_record_with_dependencies
)
record_with_dependencies
=
db
.
Record
().
add_parent
(
not_included_rt
)
record_with_dependencies
.
id
=
2004
record_with_dependencies
.
id
=
2004
record_with_dependencies
.
add_property
(
rt_dep
,
record_dep
)
record_with_dependencies
.
add_property
(
not_included_rt
,
record_referenced
)
record_with_parent
=
db
.
Record
().
add_parent
(
rt_record_with_parent
)
record_with_parent
=
db
.
Record
().
add_parent
(
rt_record_with_parent
)
record_with_parent
.
id
=
2005
record_with_parent
.
id
=
2005
record_with_property_which_is_not_a_record
=
db
.
Record
(
record_with_property_which_is_not_a_record
=
db
.
Record
(
).
add_parent
(
rt_record_without_dependencies
)
).
add_parent
(
not_included_rt
)
record_with_property_which_is_not_a_record
.
id
=
2006
record_with_property_which_is_not_a_record
.
id
=
2006
record_with_property_which_is_not_a_record
.
add_property
(
record_with_property_which_is_not_a_record
.
add_property
(
property_which_is_not_a_record
)
property_which_is_not_a_record
)
...
@@ -118,7 +112,7 @@ def test_container_dependencies_for_deletion():
...
@@ -118,7 +112,7 @@ def test_container_dependencies_for_deletion():
rt
,
rt
,
rt_record_with_parent
,
# 1005, dependency
rt_record_with_parent
,
# 1005, dependency
record_without_dependencies
,
record_without_dependencies
,
record_
dep
,
# 2002, dependency
record_
referenced
,
# 2002, dependency
record_with_dependencies
,
record_with_dependencies
,
record_with_parent
,
record_with_parent
,
record_with_property_which_is_not_a_record
record_with_property_which_is_not_a_record
...
...
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