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
Titouan Soulard
slapos.core
Commits
60ea2776
Commit
60ea2776
authored
Nov 14, 2024
by
Romain Courteaud
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
slapos_pdm: non validated allocation supply do not impact the software installation deletion
parent
fac83d69
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
3 deletions
+2
-3
master/bt5/slapos_pdm/SkinTemplateItem/portal_skins/slapos_pdm/SoftwareInstallation_destroyIfUnused.py
..._skins/slapos_pdm/SoftwareInstallation_destroyIfUnused.py
+1
-2
master/bt5/slapos_pdm/TestTemplateItem/portal_components/test.erp5.testSlapOSPDMDestroySoftwareInstallation.py
...nts/test.erp5.testSlapOSPDMDestroySoftwareInstallation.py
+1
-1
No files found.
master/bt5/slapos_pdm/SkinTemplateItem/portal_skins/slapos_pdm/SoftwareInstallation_destroyIfUnused.py
View file @
60ea2776
...
...
@@ -43,9 +43,8 @@ for allocation_cell in portal.portal_catalog(
resource__uid
=
software_product
.
getUid
(),
software_release__uid
=
software_release
.
getUid
()
):
if
allocation_cell
.
isAllocable
():
if
allocation_cell
.
isAllocable
()
and
(
allocation_cell
.
getValidationState
()
==
'validated'
)
:
return
# XXX check validation state
partition
=
portal
.
portal_catalog
.
getResultValue
(
portal_type
=
'Compute Partition'
,
...
...
master/bt5/slapos_pdm/TestTemplateItem/portal_components/test.erp5.testSlapOSPDMDestroySoftwareInstallation.py
View file @
60ea2776
...
...
@@ -109,5 +109,5 @@ class TestSlapOSDestroySoftwareInstallation(SlapOSTestCaseMixin):
self
.
tic
()
software_installation
.
SoftwareInstallation_destroyIfUnused
()
self
.
assertEqual
(
'
start
_requested'
,
software_installation
.
getSlapState
())
self
.
assertEqual
(
'
destroy
_requested'
,
software_installation
.
getSlapState
())
self
.
assertEqual
(
'validated'
,
software_installation
.
getValidationState
())
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