-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
changed the structure of the plain nightwatch example tests and also …
…renamed the files
- Loading branch information
christine.zierold
committed
Mar 16, 2017
1 parent
15b1139
commit 138701e
Showing
2 changed files
with
28 additions
and
24 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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,28 @@ | ||
module.exports = { | ||
tags: ['simpletest'], | ||
disabled: false, | ||
|
||
'Google Simple Search Test' : function (client) { | ||
const searchObject = 'Germany'; | ||
|
||
client | ||
.url('https://www.google.no/') | ||
.waitForElementVisible('#hplogo', 2000); | ||
|
||
client.expect.element('body').to.be.present; | ||
|
||
client.logger('Check Attributes'); | ||
client.expect.element('body').to.have.attribute('class').which.contains('vasq'); | ||
client.expect.element('body').to.have.attribute('onload'); | ||
|
||
client.expect.element('#hplogo').text.to.match(/Nor/); | ||
client.expect.element('#lst-ib').to.be.an('input'); | ||
|
||
client.logger('Search for ' + searchObject); | ||
client.setValue('#lst-ib', searchObject); | ||
client.expect.element('#lst-ib').to.have.value.equal(searchObject); | ||
client | ||
.keys(client.Keys.ENTER) | ||
.waitForElementVisible('#search', 2000); | ||
} | ||
}; |