Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.core
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
0
Merge Requests
0
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
Carlos Ramos Carreño
slapos.core
Commits
76c8a5c0
Commit
76c8a5c0
authored
May 29, 2012
by
Romain Courteaud
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Damaged XML only raise when changing instance state
parent
4f8520e5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
30 additions
and
8 deletions
+30
-8
master/product/Vifib/tests/testVifibSlapComputerGetComputerPartitionList.py
...ib/tests/testVifibSlapComputerGetComputerPartitionList.py
+30
-8
No files found.
master/product/Vifib/tests/testVifibSlapComputerGetComputerPartitionList.py
View file @
76c8a5c0
...
@@ -711,22 +711,44 @@ class TestVifibSlapComputerGetComputerPartitionList(TestVifibSlapWebServiceMixin
...
@@ -711,22 +711,44 @@ class TestVifibSlapComputerGetComputerPartitionList(TestVifibSlapWebServiceMixin
software_instance
.
edit
(
connection_xml
=
""
)
software_instance
.
edit
(
connection_xml
=
""
)
def
stepDamageSoftwareInstanceSlaXml
(
self
,
sequence
,
**
kw
):
def
stepDamageSoftwareInstanceSlaXml
(
self
,
sequence
,
**
kw
):
software_
instance
=
self
.
portal
.
portal_catalog
.
getResultValue
(
instance
=
self
.
portal
.
portal_catalog
.
getResultValue
(
uid
=
sequence
[
'software_instance_uid'
])
uid
=
sequence
[
'software_instance_uid'
])
software_instance
.
edit
(
sla_xml
=
"""
if
instance
.
getPortalType
()
==
"Software Instance"
:
DAMAGED<BAD?xml XMLversion="1.0" encoding="utf-8"?>"""
)
shared
=
False
elif
instance
.
getPortalType
()
==
"Slave Instance"
:
shared
=
True
else
:
raise
NotImplementedError
self
.
assertRaises
(
ValidationFailed
,
instance
.
requestStart
,
software_release
=
instance
.
getRootSoftwareReleaseUrl
(),
instance_xml
=
instance
.
getTextContent
(),
software_type
=
instance
.
getSourceReference
(),
sla_xml
=
"""DAMAGED<BAD?xml XMLversion="1.0" encoding="utf-8"?>"""
,
shared
=
shared
,
)
def
stepDamageSoftwareInstanceConnectionXml
(
self
,
sequence
,
**
kw
):
def
stepDamageSoftwareInstanceConnectionXml
(
self
,
sequence
,
**
kw
):
software_
instance
=
self
.
portal
.
portal_catalog
.
getResultValue
(
instance
=
self
.
portal
.
portal_catalog
.
getResultValue
(
uid
=
sequence
[
'software_instance_uid'
])
uid
=
sequence
[
'software_instance_uid'
])
software_
instance
.
edit
(
connection_xml
=
"""
instance
.
edit
(
connection_xml
=
"""
DAMAGED<BAD?xml XMLversion="1.0" encoding="utf-8"?>"""
)
DAMAGED<BAD?xml XMLversion="1.0" encoding="utf-8"?>"""
)
def
stepDamageSoftwareInstanceXml
(
self
,
sequence
,
**
kw
):
def
stepDamageSoftwareInstanceXml
(
self
,
sequence
,
**
kw
):
software_
instance
=
self
.
portal
.
portal_catalog
.
getResultValue
(
instance
=
self
.
portal
.
portal_catalog
.
getResultValue
(
uid
=
sequence
[
'software_instance_uid'
])
uid
=
sequence
[
'software_instance_uid'
])
self
.
assertRaises
(
ValidationFailed
,
software_instance
.
edit
,
if
instance
.
getPortalType
()
==
"Software Instance"
:
text_content
=
"""DAMAGED<BAD?xml XMLversion="1.0" encoding="utf-8"?>"""
)
shared
=
False
elif
instance
.
getPortalType
()
==
"Slave Instance"
:
shared
=
True
else
:
raise
NotImplementedError
self
.
assertRaises
(
ValidationFailed
,
instance
.
requestStart
,
software_release
=
instance
.
getRootSoftwareReleaseUrl
(),
instance_xml
=
"""DAMAGED<BAD?xml XMLversion="1.0" encoding="utf-8"?>"""
,
software_type
=
instance
.
getSourceReference
(),
sla_xml
=
instance
.
getSlaXml
(),
shared
=
shared
,
)
def
stepCheckDamageSoftwareInstanceSiteConsistency
(
self
,
sequence
,
**
kw
):
def
stepCheckDamageSoftwareInstanceSiteConsistency
(
self
,
sequence
,
**
kw
):
software_instance
=
self
.
portal
.
portal_catalog
.
getResultValue
(
software_instance
=
self
.
portal
.
portal_catalog
.
getResultValue
(
...
...
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