Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
opcua-asyncio
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Nikola Balog
opcua-asyncio
Commits
eb2e16e6
Commit
eb2e16e6
authored
Oct 24, 2016
by
olivier R-D
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add test for xml import of nodeid variant
parent
257aad10
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
3 deletions
+8
-3
tests/tests_xml.py
tests/tests_xml.py
+8
-3
No files found.
tests/tests_xml.py
View file @
eb2e16e6
...
...
@@ -232,9 +232,6 @@ class XmlTests(object):
o
=
self
.
opc
.
nodes
.
objects
.
add_variable
(
2
,
"xmlstringarray"
,
[
"mystring2"
,
"mystring3"
])
node2
=
self
.
_test_xml_var_type
(
o
,
"stringarray"
)
dv
=
node2
.
get_data_value
()
#from IPython import embed
#embed()
#dv.Value.ArrayDimensions = [2]
def
test_xml_guid
(
self
):
o
=
self
.
opc
.
nodes
.
objects
.
add_variable
(
2
,
"xmlguid"
,
uuid
.
uuid4
())
...
...
@@ -244,6 +241,14 @@ class XmlTests(object):
o
=
self
.
opc
.
nodes
.
objects
.
add_variable
(
2
,
"xmlltext"
,
ua
.
LocalizedText
(
"mytext"
))
self
.
_test_xml_var_type
(
o
,
"localized_text"
)
def
test_xml_localizedtext_array
(
self
):
o
=
self
.
opc
.
nodes
.
objects
.
add_variable
(
2
,
"xmlltext_array"
,
[
ua
.
LocalizedText
(
"erert"
),
ua
.
LocalizedText
(
"erert33"
)])
self
.
_test_xml_var_type
(
o
,
"localized_text_array"
)
def
test_xml_nodeid
(
self
):
o
=
self
.
opc
.
nodes
.
objects
.
add_variable
(
2
,
"xmlnodeid"
,
ua
.
NodeId
(
"mytext"
,
1
))
self
.
_test_xml_var_type
(
o
,
"nodeid"
)
def
_test_xml_var_type
(
self
,
node
,
typename
):
dtype
=
node
.
get_data_type
()
dv
=
node
.
get_data_value
()
...
...
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