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
Boxiang Sun
slapos.core
Commits
6f3947bb
Commit
6f3947bb
authored
Aug 02, 2011
by
Gabriel Monnerat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
reuse function to find the software instance installed on current computer partition
parent
4e62f9c5
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
14 deletions
+7
-14
master/product/Vifib/tests/testVifibSlapWebService.py
master/product/Vifib/tests/testVifibSlapWebService.py
+7
-14
No files found.
master/product/Vifib/tests/testVifibSlapWebService.py
View file @
6f3947bb
...
@@ -6350,20 +6350,13 @@ class TestVifibSlapWebService(testVifibMixin):
...
@@ -6350,20 +6350,13 @@ class TestVifibSlapWebService(testVifibMixin):
self
.
assertUserCanAccessDocument
(
username
,
slave_instance
)
self
.
assertUserCanAccessDocument
(
username
,
slave_instance
)
def
stepSlapLoginSoftwareInstanceFromCurrentSoftwareInstance
(
self
,
sequence
):
def
stepSlapLoginSoftwareInstanceFromCurrentSoftwareInstance
(
self
,
sequence
):
computer_partition
=
self
.
portal
.
portal_catalog
.
getResultValue
(
software_instance
=
self
.
_getSoftwareInstanceFromCurrentComputerPartition
(
uid
=
sequence
[
"computer_partition_uid"
])
sequence
)
sale_packing_list_line_list
=
self
.
portal
.
portal_catalog
(
self
.
assertNotEquals
(
None
,
software_instance
)
portal_type
=
"Sale Packing List Line"
,
aggregate_uid
=
computer_partition
.
getUid
())
for
sale_packing_list_line
in
sale_packing_list_line_list
:
software_instance
=
sale_packing_list_line
.
getAggregateValue
(
portal_type
=
"Software Instance"
)
if
software_instance
is
not
None
:
self
.
stepSlapLogout
()
self
.
stepSlapLogout
()
global
REMOTE_USER
global
REMOTE_USER
REMOTE_USER
=
software_instance
.
getReference
()
REMOTE_USER
=
software_instance
.
getReference
()
self
.
login
(
software_instance
.
getReference
())
self
.
login
(
software_instance
.
getReference
())
break
def
_getSoftwareInstanceFromCurrentComputerPartition
(
self
,
sequence
):
def
_getSoftwareInstanceFromCurrentComputerPartition
(
self
,
sequence
):
query
=
ComplexQuery
(
query
=
ComplexQuery
(
...
...
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