mirror of
https://github.com/ansible/awx.git
synced 2026-05-08 18:07:36 -02:30
Updating e2e tests to match new settings nav
This commit is contained in:
@@ -1,9 +1,7 @@
|
|||||||
module.exports = {
|
module.exports = {
|
||||||
'expected LDAP codemirror fields are rendered when returning from another tab': client => {
|
'expected LDAP codemirror fields are rendered when returning from another tab': client => {
|
||||||
const authTab = '#auth_tab';
|
|
||||||
const authView = 'div[ui-view="auth"]';
|
const authView = 'div[ui-view="auth"]';
|
||||||
const ldapForm = '#configuration_ldap_template_form';
|
const ldapForm = '#configuration_ldap_template_form';
|
||||||
const systemTab = '#system_tab';
|
|
||||||
const systemView = 'div[ui-view="system"]';
|
const systemView = 'div[ui-view="system"]';
|
||||||
|
|
||||||
const { navigation } = client.page.dashboard().section;
|
const { navigation } = client.page.dashboard().section;
|
||||||
@@ -14,20 +12,22 @@ module.exports = {
|
|||||||
|
|
||||||
navigation
|
navigation
|
||||||
.waitForElementVisible('@settings')
|
.waitForElementVisible('@settings')
|
||||||
.click('@settings');
|
.moveToElement('@settings',0,0)
|
||||||
|
.waitForElementVisible('@settingsSubPaneSystem')
|
||||||
|
.click('@settingsSubPaneSystem');
|
||||||
|
|
||||||
configuration.waitForElementVisible(authView);
|
|
||||||
|
|
||||||
configuration.waitForElementVisible(systemTab);
|
|
||||||
configuration.click(systemTab);
|
|
||||||
configuration.waitForElementNotVisible(authView);
|
|
||||||
configuration.waitForElementVisible(systemView);
|
configuration.waitForElementVisible(systemView);
|
||||||
|
|
||||||
configuration.waitForElementVisible(authTab);
|
navigation
|
||||||
configuration.click(authTab);
|
.waitForElementVisible('@settings')
|
||||||
configuration.waitForElementNotVisible(systemView);
|
.moveToElement('@settings',0,0)
|
||||||
|
.waitForElementVisible('@settingsSubPane')
|
||||||
|
.waitForElementVisible('@settingsSubPaneAuth')
|
||||||
|
.click('@settingsSubPaneAuth');
|
||||||
|
|
||||||
configuration.waitForElementVisible(authView);
|
configuration.waitForElementVisible(authView);
|
||||||
|
|
||||||
|
// works as xpath const categoryName = `//*[@id="configuration_edit"]/div[1]/div/div/div[4]`;
|
||||||
configuration.selectSubcategory('LDAP');
|
configuration.selectSubcategory('LDAP');
|
||||||
configuration.waitForElementVisible(ldapForm);
|
configuration.waitForElementVisible(ldapForm);
|
||||||
|
|
||||||
@@ -41,7 +41,7 @@ module.exports = {
|
|||||||
'AUTH_LDAP_TEAM_MAP',
|
'AUTH_LDAP_TEAM_MAP',
|
||||||
];
|
];
|
||||||
|
|
||||||
const ldapCodeMirrors = `${ldapForm} div[class^="CodeMirror"] textarea`;
|
const ldapCodeMirrors = `${ldapForm} div[class^="CodeMirror"] textarea`;
|
||||||
|
|
||||||
client.elements('css selector', ldapCodeMirrors, ({ value }) => {
|
client.elements('css selector', ldapCodeMirrors, ({ value }) => {
|
||||||
client.assert.equal(value.length, expectedCodemirrorFields.length);
|
client.assert.equal(value.length, expectedCodemirrorFields.length);
|
||||||
|
|||||||
Reference in New Issue
Block a user