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
Paul Graydon
slapos.core
Commits
90baf24e
Commit
90baf24e
authored
Aug 20, 2012
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use site code to setup PAS.
parent
73e009e5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
34 deletions
+2
-34
master/product/Vifib/tests/VifibMixin.py
master/product/Vifib/tests/VifibMixin.py
+2
-34
No files found.
master/product/Vifib/tests/VifibMixin.py
View file @
90baf24e
...
@@ -281,38 +281,6 @@ class testVifibMixin(ERP5TypeTestCase):
...
@@ -281,38 +281,6 @@ class testVifibMixin(ERP5TypeTestCase):
self
.
markManualCreation
(
accounting_period
)
self
.
markManualCreation
(
accounting_period
)
accounting_period
.
start
()
accounting_period
.
start
()
def
setupVifibMachineAuthenticationPlugin
(
self
):
"""Sets up Vifib Authentication plugin"""
pas
=
self
.
getPortal
().
acl_users
vifib_auth_list
=
[
q
for
q
in
pas
.
objectValues
()
\
if
q
.
meta_type
==
'Vifib Machine Authentication Plugin'
]
if
len
(
vifib_auth_list
)
==
0
:
vifib_dispacher
=
pas
.
manage_addProduct
[
'Vifib'
]
vifib_dispacher
.
addVifibMachineAuthenticationPlugin
(
'vifib_auth'
)
vifib_auth
=
pas
.
vifib_auth
else
:
if
len
(
vifib_auth_list
)
>
1
:
raise
ValueError
(
'More then one Vifib authentication'
)
vifib_auth
=
vifib_auth_list
[
0
]
vifib_auth
.
manage_activateInterfaces
((
'IAuthenticationPlugin'
,
'IExtractionPlugin'
,
'IGroupsPlugin'
,
'IUserEnumerationPlugin'
))
def
setupVifibShadowAuthenticationPlugin
(
self
):
"""Sets up Vifib Authentication plugin"""
pas
=
self
.
getPortal
().
acl_users
vifib_auth_list
=
[
q
for
q
in
pas
.
objectValues
()
\
if
q
.
meta_type
==
'Vifib Shadow Authentication Plugin'
]
if
len
(
vifib_auth_list
)
==
0
:
vifib_dispacher
=
pas
.
manage_addProduct
[
'Vifib'
]
vifib_dispacher
.
addVifibShadowAuthenticationPlugin
(
'vifib_auth_shadow'
)
vifib_auth
=
pas
.
vifib_auth_shadow
else
:
if
len
(
vifib_auth_list
)
>
1
:
raise
ValueError
(
'More then one Vifib Shadow authentication'
)
vifib_auth
=
vifib_auth_list
[
0
]
vifib_auth
.
manage_activateInterfaces
((
'IAuthenticationPlugin'
,
'IGroupsPlugin'
,
'IUserEnumerationPlugin'
))
def
bootstrapSite
(
self
):
def
bootstrapSite
(
self
):
"""
"""
Manager has to create an administrator user first.
Manager has to create an administrator user first.
...
@@ -338,8 +306,8 @@ class testVifibMixin(ERP5TypeTestCase):
...
@@ -338,8 +306,8 @@ class testVifibMixin(ERP5TypeTestCase):
self
.
logMessage
(
"Bootstrap Vifib Without Security..."
)
self
.
logMessage
(
"Bootstrap Vifib Without Security..."
)
self
.
login
()
self
.
login
()
self
.
setupVifibMachineAuthenticationPlugin
()
# setup Vifib PAS
self
.
setupVifibShadowAuthenticationPlugin
()
self
.
portal
.
portal_alarms
.
vifib_promise_pas
.
solve
()
self
.
prepareTestUsers
()
self
.
prepareTestUsers
()
self
.
prepareVifibAccountingPeriod
()
self
.
prepareVifibAccountingPeriod
()
transaction
.
commit
()
transaction
.
commit
()
...
...
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