-
Notifications
You must be signed in to change notification settings - Fork 50
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update test to work with test string update and add test for new
edit description implementation
- Loading branch information
1 parent
a3a12aa
commit 968923b
Showing
4 changed files
with
107 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
// Edit Description page | ||
|
||
class EditDescriptionPage { | ||
constructor() { | ||
this.containerSelector = '[id="cmpsr-modal-edit-description"]'; | ||
} | ||
|
||
loading() { | ||
browser.waitUntil( | ||
() => browser.isExisting(this.containerSelector), | ||
timeout, | ||
`Loading Edit Description page failed because selector ${this.containerSelector} cannot be found` | ||
); | ||
} | ||
|
||
get xButton() { | ||
const selector = `${this.containerSelector} .pficon-close`; | ||
browser.waitUntil( | ||
() => browser.isExisting(selector), | ||
timeout, | ||
`X button under Edit Description page cannot be found by selector ${selector}` | ||
); | ||
return $(selector); | ||
} | ||
|
||
get descriptionInputBox() { | ||
const selector = `${this.containerSelector} [id="textInput-modal-markup"]`; | ||
browser.waitUntil( | ||
() => browser.isExisting(selector), | ||
timeout, | ||
`blueprint description input box under Edit Description page cannot be found by selector ${selector}` | ||
); | ||
return $(selector); | ||
} | ||
|
||
get saveButton() { | ||
const selector = `${this.containerSelector} [id="edit-description-modal-submit-button"]`; | ||
browser.waitUntil( | ||
() => browser.isExisting(selector), | ||
timeout, | ||
`Save button under Edit Description page cannot be found by selector ${selector}` | ||
); | ||
return $(selector); | ||
} | ||
|
||
get cancelButton() { | ||
const selector = `${this.containerSelector} .btn-default`; | ||
browser.waitUntil( | ||
() => browser.isExisting(selector), | ||
timeout, | ||
`Cancel button under Edit Description page cannot be found by selector ${selector}` | ||
); | ||
return $(selector); | ||
} | ||
} | ||
module.exports = new EditDescriptionPage(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters