Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
slapos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
106
Merge Requests
106
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
nexedi
slapos
Commits
f7c25c3b
Commit
f7c25c3b
authored
Jan 04, 2024
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
864c6de5
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
4 deletions
+7
-4
software/ors-amarisoft/test/test.py
software/ors-amarisoft/test/test.py
+7
-4
No files found.
software/ors-amarisoft/test/test.py
View file @
f7c25c3b
...
...
@@ -256,7 +256,7 @@ class TestENB_SDR(ENBTestCase):
# assertDict asserts that d slice with keys from dok == dok.
# dok[k]=NO means d[k] must be absent.
# XXX -> assertatch with support for {} and []
# XXX -> assert
M
atch with support for {} and []
class
NOClass
:
def
__repr__
(
self
):
return
'ø'
...
...
@@ -269,8 +269,10 @@ class TestENB_SDR(ENBTestCase):
# assertMatch recursively matches data structure against specified pattern.
#
# atomic types like int and str match by equality
# container types like dict and list match
# - atomic types like int and str match by equality
# - list match by matching all elements individually
# - dict match by verifying v[k] == vok[k] for keys from the pattern
# vok[k]=NO means v[k] must be absent
def
assertMatch
(
v
,
vok
):
v_
=
_matchCollect
(
v
,
vok
)
self
.
assertEqual
(
v_
,
vok
)
...
...
@@ -302,6 +304,7 @@ class TestENB_SDR(ENBTestCase):
return
v_
# other types, e.g. atomic int/str/... - return as is
assert
type
(
v
)
is
not
tuple
,
v
return
v
cell_list
=
conf
[
'cell_list'
]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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