mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
Web UI Integration tests: Kerberos Flags
Tests according to: http://www.freeipa.org/page/V3/Kerberos_Flags https://fedorahosted.org/freeipa/ticket/3831
This commit is contained in:
parent
8e8afe0519
commit
0584caf56a
@ -198,6 +198,27 @@ class test_host(host_tasks):
|
||||
self.navigate_by_breadcrumb('Hosts')
|
||||
self.delete_record(self.pkey, self.data.get('del'))
|
||||
|
||||
def test_kerberos_flags(self):
|
||||
"""
|
||||
Test Kerberos flags
|
||||
http://www.freeipa.org/page/V3/Kerberos_Flags
|
||||
"""
|
||||
pkey = self.config.get('ipa_server')
|
||||
name = 'ipakrbokasdelegate'
|
||||
mod = {'mod': [('checkbox', name, '')]}
|
||||
checked = ['checked']
|
||||
|
||||
self.init_app()
|
||||
self.navigate_to_record(pkey, entity=ENTITY)
|
||||
|
||||
if self.get_field_checked(name) == checked:
|
||||
self.mod_record(ENTITY, mod) # uncheck
|
||||
|
||||
self.mod_record(ENTITY, mod)
|
||||
self.validate_fields([('checkbox', name, checked)])
|
||||
self.mod_record(ENTITY, mod)
|
||||
self.validate_fields([('checkbox', name, [])])
|
||||
|
||||
def test_associations(self):
|
||||
"""
|
||||
Host direct associations
|
||||
|
@ -51,6 +51,12 @@ class sevice_tasks(UI_driver):
|
||||
csr = csr_file.read()
|
||||
return csr
|
||||
|
||||
def get_http_pkey(self):
|
||||
host = self.config.get('ipa_server')
|
||||
realm = self.config.get('ipa_realm')
|
||||
pkey = 'HTTP/%s@%s' % (host, realm)
|
||||
return pkey
|
||||
|
||||
|
||||
class test_service(sevice_tasks):
|
||||
|
||||
@ -158,10 +164,29 @@ class test_service(sevice_tasks):
|
||||
|
||||
# test HTTP, which should have cert set by default and so 'view' and 'get'
|
||||
# actions visible and enabled
|
||||
host = self.config.get('ipa_server')
|
||||
realm = self.config.get('ipa_realm')
|
||||
pkey = 'HTTP/%s@%s' % (host, realm)
|
||||
pkey = self.get_http_pkey()
|
||||
|
||||
self.navigate_to_record(pkey)
|
||||
self.assert_action_panel_action(panel, 'view_cert')
|
||||
self.assert_action_panel_action(panel, 'get_cert')
|
||||
|
||||
def test_kerberos_flags(self):
|
||||
"""
|
||||
Test Kerberos flags
|
||||
http://www.freeipa.org/page/V3/Kerberos_Flags
|
||||
"""
|
||||
pkey = self.get_http_pkey()
|
||||
name = 'ipakrbokasdelegate'
|
||||
mod = {'mod': [('checkbox', name, '')]}
|
||||
checked = ['checked']
|
||||
|
||||
self.init_app()
|
||||
self.navigate_to_record(pkey, entity=ENTITY)
|
||||
|
||||
if self.get_field_checked(name) == checked:
|
||||
self.mod_record(ENTITY, mod) # uncheck
|
||||
|
||||
self.mod_record(ENTITY, mod)
|
||||
self.validate_fields([('checkbox', name, checked)])
|
||||
self.mod_record(ENTITY, mod)
|
||||
self.validate_fields([('checkbox', name, [])])
|
||||
|
Loading…
Reference in New Issue
Block a user