-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NameSpace Admin page locators actions and step definition addition #16
base: develop
Are you sure you want to change the base?
Conversation
@FindBy(how = How.XPATH, using = "//a[contains(text(),\"Switch to\")]") | ||
public static WebElement switchToNameSpaceButton; | ||
|
||
@FindBy(how = How.XPATH, using = "//div[@class=\"namespace-and-caret\"]") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we can find an Id for these locators we should use them. As class names can be changed in UI mostly.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
CdfNameSpaceAdminActions.switchToNewNameSpace(); | ||
} | ||
|
||
@Then("Verify if the switch is successful by checking the current {string} value") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It can be changed something like, 'Verify the namespace is switched to {string} successfully'
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes changed it to the desired statement .
CdfNameSpaceAdminLocators.nameSpaceModules(tabName, nameSpaceName)); | ||
} | ||
|
||
public static void clickOnNameSpaceAdminTab() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change the method as this and the above one has the same naming only having added s letter.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes changed the method name to openNamespaceAdminPage()
ElementHelper.clickOnElement(CdfNameSpaceAdminLocators.editPreferencesButton); | ||
} | ||
|
||
public static void switchOnNameSpace(String nameSpaceName) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
switchOnNameSpace
to switchToNameSpace
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done , changed
ElementHelper.clickOnElement(CdfNameSpaceAdminLocators.switchNameSpace(nameSpaceName)); | ||
} | ||
|
||
public static void createProfileforNameSpace(String nameSpaceName) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix the came casing : createProfileforNameSpace
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
changed to createProfileForNamespace()
} | ||
|
||
public static void addNameSpacefromHamnugerMenu() { | ||
ElementHelper.clickOnElement(CdfNameSpaceAdminLocators.addNamespace); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix the camel casing in above 2 method names.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also fix the Hamburger spelling.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed the spelling , changed the method name to addNamespaceFromHamburgerMenu()
} | ||
|
||
/** | ||
* Verify if the added Preferences reset is validated successfully |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Verify if the added Preferences reset is validated successfully
to Verify if the added Preferences reset is successful
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed the comment to Verify if the added Preferences reset is successful
CdfNameSpaceAdminActions.selectHamburgerMenuList(tabName); | ||
} | ||
|
||
@Then("Set nameSpace preferences with key: {string} and value: {string}") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe we should write the Step definitions normally and not in camel case, name space is fine.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks , changed it to namespace
CdfPluginPropertiesActions.replaceValueInInputProperty("projectId", "projectId"); | ||
} | ||
|
||
@Then("Verify that the user is navigated to nameSpace admin page successfully") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Verify that the user is navigated to nameSpace admin page successfully
to
Verify if user sucessfully navigated to name space admin page
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed it to the desired statement .
} | ||
|
||
@Then("Verify that the user is navigated to nameSpace admin page successfully") | ||
public void verifyThatHubPageIsSuccessfullyOpened() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also the method name should be relevant with the step here the method says verify if hub page is opened but in step we are saying verify is user is navigated to name space admin page
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes , changed it to verifyThatNamespacePageIsSuccessfullyOpened()
bc441b9
to
ca3dc6d
Compare
ca3dc6d
to
86c646f
Compare
…ors were removed which were common in Sys admin and Namespace admin . Sys admin FW PR is merged
Page object model setup for New module Namespace admin .
New locators , actions and step def added .